Simple Hyperledger Fabric application. There are two organization:
- org1 (can send proposals and invoke chaincode)
- org2 (read-only, can view blocks)
In order to raise sample network:
- Copy this repository and change working directory to "network"
git clone git@github.com:KirillovDenis/hlf-voting-sample.git
cd hlf-voting-sample/network
- Up network
./raiseNetwork.sh
To interact with chaincode java sdk are used. Run application.
cd client/hlf-voting-sample
mvn exec:java
To read block need change 'org1' client organization to 'org2' in 'client/hlf-voting-samples/src/main/resources/network-config.yaml' Then run
Go to the resource folder
cd client/hlf-voting-sample/src/main/resources
Change 'org1' client organization to 'org2' in 'network-config.yaml' file
cd client/hlf-voting-sample
mvn exec:java
In order to remove network change working directory to "network" and run the following script
./clear.sh