#使用IBM Bluemix Blockchain Service在 Blockchain Network 开发 chaincode
Email:[email protected]go version go1.7 windows/amd64
v6.5.0
2.15.9
git version 2.9.3
登入github 建立账号 (https://github.com/ 纪录 username 及 password)
安装 github desktop (https://desktop.github.com/)
--
global user.name “github username” (github username=账号) < github username>
浏览器:https://github.com/IBM-Blockchain/learn-chaincode (点选 fork )
service 环境必须使用安装在 github 内之 chaincode.
(若有誤修正) *shim.ChaincodeStub => shim.ChaincodeStubInterface
{
“enrollId”: “user_type1_736394e032”,
“enrollSecret”: “7a59adadco”
}
path: 步骤 9
secureContext: 步骤 21
{
“jsonrpc”: “2.0”,
“method”: “deploy”,
“params”: {
“type”: 1,
“chaincodeID”: {
“path”: “https://github.com/xxxxxxxxxxx/learn-chaincode/finished”
},
“ctorMsg”: {
“function”: “init”,
“args”: [
“hi there”
]
},
“secureContext”: “user_type1_xxxxxxxxxxxxxxxxxxxxx”
},
“id”: 1
}
若要执行已安装在 peer之 chaincode 则参考 chaincode ID 即可
chaincodeId: 步骤 25
secureContext: 步骤 21
{
“jsonrpc”: “2.0”,
“method”: “query”,
“params”: {
“type”: 1,
“chaincodeID”: {
“name”: “xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx”
},
“ctorMsg”: {
“function”: “read”,
“args”: [
“hello_world”
]
},
“secureContext”: “user_type1_xxxxxxxxx”
},
“id”: 2
}
chaincodeId: 步骤 25
secureContext: 步骤 21
{
"jsonrpc": "2.0",
"method": "invoke",
"params": {
"type": 1,
"chaincodeID": {
"name": "xxxxxxxxxxxxxxxxxxxxxx"
},
"ctorMsg": {
"function": "write",
"args": [
"hello_world",
"go away"
]
},
"secureContext": "user_type1_xxxxxxxxx"
},
"id": 3
}
1.bluemix 全球系统维护现况
2.Bluemix 可选择 Region
api.ng.bluemix.net (US South)
api.eu-gb.bluemix.net (United Kingdom)
api.au-syd.bluemix.net (Sydney)
1.https://github.com/IBM-Blockchain/learn-chaincode
2.https://www.ibm.com/internet-of-things/iot-news/announcements/private-blockchain/ 点选 [play]
3.https://console.ng.bluemix.net/docs/services/blockchain/ibmblockchain_tutorials.html
4.https://github.com/hyperledger
5.http://www.ibm.com/blockchain/for_developers.html
6.https://github.com/IBM-Blockchain/chaincode-investigator
7.https://console.ng.bluemix.net/docs/services/IoT/blockchain/dev_blockchain.html
8.https://console.ng.bluemix.net/docs/services/IoT/bl_blockchain_integration.html
9.https://console.ng.bluemix.net/docs/services/IoT/reference/extensions/index.html
10.http://bramwelt-fabric.readthedocs.io/en/latest/FAQ/chaincode_FAQ.html
11.http://www.multichain.com/blog/2016/04/beware-impossible-smart-contract/
12.https://github.com/ibm-watson-iot/blockchain-samples/tree/master/simple_contract_hyperledger
13.https://github.com/hyperledger/fabric/blob/master/docs/API/CoreAPI.md?cm_mc_uid=61030309207314713163325&cm_mc_sid_50200000=1473623034#chaincode
14.https://1drv.ms/f/s!AkBmzWP0h-Vxbr7h1uTNsTMcPWI
15.https://1drv.ms/b/s!AkBmzWP0h-VxazOBOsVz8nGMLpM
16.https://1drv.ms/b/s!AkBmzWP0h-VxbLK7FOjH9IL5HHc
17.https://www.youtube.com/watch?v=24JAF9Eu1mk&list=UUOTZe-b_jE_Ovy9K9UhZ4BA&index=74
18.https://www.youtube.com/watch?v=wSmJ-rwUo8I&list=UUOTZe-b_jE_Ovy9K9UhZ4BA&index=73
19.https://www.youtube.com/watch?v=SOsn6MvGH60&list=UUOTZe-b_jE_Ovy9K9UhZ4BA&index=72