m Fabric Deployments
Key Points
many deployment options exist
deployment tools include
- minifabric
- vagrant
- minikube
- cello
- bafe
References
Reference_description_with_linked_URLs_______________________ | Notes______________________________________________________________ |
---|---|
SWT hyperledger page | |
hyperledger projects list | https://www.hyperledger.org/use |
hyperledger labs list | https://labs.hyperledger.org/ |
hyperledger repos list | |
hyperledger wiki pages | https://wiki.hyperledger.org/display/labs |
Key Concepts
Fabric Deployment Planning Guidance
Fabric Solution Planning
Best Practices
- Plan ahead – it’s important to make the correct architectural decisions from the get-go because with Blockchain, it can be difficult to modify the data model and operations.
- Start small, work on a proof of concept, and learn the technology.
- Define and document the network structure, participants, and transaction committing rules.
- Work with network participants to outline the minimum requirements for the nodes, so performance is not hindered by the weakest link.
- Always use encryption and mutual TLS when it comes to communication among network nodes.
- Use two separate Certificate Authority (CA) servers per organization. One CA to manage the organization’s identity certificates and one to manage the TLS certificates.
- Plan to have monitoring and alerting services to avoid problems with the network, and keep it performing as expected. The more participants the network has, the higher the overhead will be.
- When using CouchDB always consider creating indexes for fetching data from the peer Key Value Store (KVS).
Fabric Tips
- Tip: Always consult HLF and HLF CA documentation on their official websites. Be sure to pick the correct version that corresponds to the version of HL software components used.
- Tip: When possible, start with the most recent LTS (Long Term Support) release of HLF software. Pick the highest version possible to get the most recent features and bug fixes.
- Tip: Use Mutual TLS to achieve best security on communication channel level. That way the nodes will verify the TLS client certificates before opening the protocol level communication.
- Tip: TLS certificates of the nodes (peers/orderers) may have the nodes’ DNS names under their certificate name’s tag. That way the nodes can be easily moved on different IP addresses without a need to change the TLS certificates.
- Tip: Usually, Kubernetes and Docker are used to orchestrate the network nodes of an organization. Both tools are open-source and well supported by their communities. No need to run the network on a VM OS directly, as this may become a challenge to maintain and operate properly.
- Tip: A peer can be removed from the network by revoking its identity and destroying its container. When removing a peer, make sure it is not an anchor peer as this may impact cross-organization operations and communications. It is best first to replace the anchor peer on the channels with a new peer and then proceed with the removal process.
- Trap: Avoid using local VM file system or volumes to store the nodes data (ledger, KVS). Instead, use attachable volumes (persistent storage) to avoid losing data when the VM crashes. Dedicated persistent storage is easily backed up and restored.
- Trap: The issued TLS certificates usually have a validity date. Make sure you rotate the certificates before they reach the end date so that the nodes and users can continue communicating without interruption. The rotation of the TLS certificates of the ordering service is an extremely important process that must be planned for upfront and executed promptly.
Tutorials
The table below provides a non-comprehensive list of links to tutorials that we’ve found to be most useful.
Tutorial Content | Summary |
Deploying a Production Network | A high-level overview of the proper sequence for setting up production Fabric network components. It discusses best practices and a few of the many considerations to keep in mind when deploying. |
Deploying a Smart Contract to a Channel | Reviews the steps necessary to have a new smart contract deployed onto the Fabric network. |
Adding an Org to a Channel | Describes the step-by-step process of adding a new organization to an existing channel. |
HLF Command Line Reference | List of commands to manage HLF networks and chain codes. |
HLF Peer Channel Commands | Detailed command description to manage and operate channels on a peer, e.g., how to join a peer on a channel. |
HLF Ordering Channel Commands | Detailed command description to manage and operate channels on an orderer, e.g., how to join an orderer on a channel or create new channels. |
How to Upgrade to a New HLF Version | Recommendations for upgrading to the newest release of HLF. |
How to Develop Applications on HLF | Detailed guideline on how to develop applications to solve a business problem with HLF. |
Private Data Collections in HLF | What Private Data Collections are and how to achieve privacy on the blockchain. |
Security Model in HLF | Overview of the HLF security model, including topics like policies, permissioning, TLS, HSM, etc. |
Hyperledger Certificate Authority User Guide | Essential information on how to operate and manage an HL CA serve, including how to register, enroll and revoke an identity. |
Introduction to Hyperledger Fabric | Learn about Hyperledger Fabric from the source, in this brief introduction to the product and the technology behind it. |
Fabric Deployment Choices
Minifabric
https://github.com/hyperledger-labs/minifabric
https://github.com/hyperledger-labs/minifabric/blob/main/docs/README.md
Working with Hyperledger Fabric can be intimidating at first, the below list is to show you the normal process of working with Fabric.
1. Stand up a Fabric network
2. Create a channel
3. Join peers to a channel
4. Install chaincode onto peers
5. Approve chaincode (only for 2.0)
6. Commit or instantiate chaincode
7. Invoke chaincode (using either minifab or your applications)
8. Query blocks
Minikube for Fabric
Vagrant
Fabric Admin custom
Cello
Fabric 3rd party hosts
Consortia
BAFE for multiple blockchain deployments
https://labs.hyperledger.org/labs/blockchain-automation-framework.html
Hyperledger Projects List
https://www.hyperledger.org/use
https://www.upgrad.com/blog/hyperledger-projects-to-drive-blockchain-adoption/
https://101blockchains.com/hyperledger-project/
Hyperledger Labs List
https://github.com/orgs/hyperledger-labs/repositories
https://wiki.hyperledger.org/display/labs
Potential Value Opportunities
Potential Challenges
Candidate Solutions
Step-by-step guide for Example
sample code block