Chaincode Workflow Demo
This demo explains the workflows discussed in Chaincode Frontend Design using screenshots.
Step 1: View chaincode list
- Once entering the chaincode page, you will see a table of all chaincode information. The table includes all chaincodes uploaded by the current org.
- You can check chaincode's packageID, version, language, description and use corresponding operations.
Step 2: Upload new chaincode
1. You can use the Upload Chaincode button to upload a new chaincode package by uploading the chaincode package file in a pop-up window.
2. chaincode package file must be in tar.gz format. Description is optional.
3. cello(frontend or backend) will parse the package file and retrieve the package information such as version, language etc.
4. You will see the new chain code in the table if uploading succeeded.
Step 3: Install chaincode
- Each organizational user installs the chain code on their respective nodes.
- To install any available chaincode onto your nodes, click the "Install" button. A pop-up window will appear, allowing you to select the desired nodes within your organization for installation.
By default, the nodes you have already installed will be automatically selected, and cannot be unchecked.
Step 4: Approve chaincode
- Each organization performs licensing operations on the chaincode.
- Click the Approve button to approve chaincode.
- You need to specify which channel to approve, the name for the approved cc and specify whether the chaincode requires invoking 'init'.
Step 5: Commit chaincode
- You can commit the chaincode to channels by clicking Commit button
- You need to choose the desired channel for committing the chaincode from the available options in the drop-down menu.
- Specify whether the chaincode requires invoking 'init' by checking/unchecking the checkbox.
4. If the current approvement does not meet the channel policies, commitment may fail and you will see a prompt window
Step 6: Check chaincode detail
- Click any row on the chaincode table, you will enter the sub-detail page, which shows all information about current cc, including PackageID, version, language, description and peer nodes the cc is installed.
- The frontend page is routing using chaincode name, the following page uses the URL path hostname/chaincodeDefinition/packageID/detail
More operations(optional):
- Delete: Delete chaincode from database if it is not used.
- Update: Go through all steps above using updated information.