原创 編程價值觀、原則、模式

讀自《實現模式》 模式,即是針對特定問題的通用解決方案。 每個模式都承載這一點點理論,但實際編程中存在着一些更加深遠的影響力,遠不是孤立的模式所能概括的。 價值觀是編程過程的統一支配性主題,影響在編程中所作的每一個決策。 價值觀有普遍的意

原创 build.gradle中的外部變量

使用gradle命令的時候,經常被Option -P\-D搞得混淆。其實很容易區分一下。 Project property 在build.gradle文件中,能直接通過變量名訪問 或者 project前綴訪問的是project proper

原创 python web scraping

最近在看《Web Scraping with Python》,藉此來熟悉Python2.7如何開始編程。 發現書上主要使用的 http://example.webscraping.com/ 網站有部分變化,書中的代碼有點無法對照使用,因此稍

原创 Docker學習筆記(一)

本地用的Docker for Mac,使用official tutorial 進行前期安裝工作。 安裝好後,運行第一個命令docker --version。 Docker version 1.12.1, build 6f9534c 官方文

原创 創建IAM

創建組 給創建的組配置策略 創建用戶 創建密碼管理和MFA 給用戶分配組 這時即可使用IAM登陸,link https://your_aws_account_id.signin.aws.amazon.com/co

原创 spring boot actuator基本配置

1.5.3版本官方doc spring-boot-actuator包自動提供了默認的management endpoint,用以監控容器內部的各種狀態和指標。 import dependencies { compile("org.spri

原创 Spring cloud Feign

1. dependency dependencies { compile("org.springframework.cloud:spring-cloud-starter-feign") …… } 2. annotation

原创 Python2.7上路

之前稍微看了下python3的網上教程和官方文檔,具體實踐做的很少。 由於後面要學習ML,目前推薦2.7版本,今次就從構建開始吧。 1. 使用pip + virtualenv進行構建 安裝virtualenv $ pip install v

原创 Spring config server

server 添加依賴 dependencies { compile 'org.springframework.cloud:spring-cloud-config-server' compile 'org.springf

原创 Vagrant setup

安裝軟件 brew cask install virtualbox brew cask install vagrant 創建project mkdir -p mst/vm cd mst/vm vagrant init hashicorp/

原创 Spring cloud Netflix中的超時配置

一般SpringCloud中超時配置,含Hystrix/Ribbon兩部分: ribbon: ReadTimeout: 120000 ConnectTimeout: 120000 hystrix: command:

原创 Solidity Zombies學習筆記

以太坊的一個加密殭屍遊戲。 爲了便於記憶,將其中的教程產出code貼了出來。 ZombieFactory.sol pragma solidity ^0.4.19; import "./ownable.sol"; contract Zomb

原创 React Native Tutorial摘要(一)

###安裝 在Mac上用homebrew安裝非常簡單: brew install node brew install watchman npm install -g react-native-cli 當然前提也需要安裝好Xcode和And

原创 在AWS Linux上安裝mongo-server

offical Tutorial 主要步驟: 創建文件/etc/yum.repos.d/mongodb-enterprise.repo。複製下面內容到文件中。 [mongodb-enterprise] name=MongoDB Ente

原创 Docker學習筆記(二)

如何創建或者更新一個image? There are two ways you can update and create images. You can update a container created from an image