Deploy Your Applications

Distributed Ledger Networks with Consortia

Your applications transact on your DLT network by executing the business logic as implemented in the deployed chaincodes. Your application layer depending on your architecture may be simple or quite complex (when for example you need to integrate with other applications in your system landscape). The HLF chaincode can be accessed and invoked by using the HLF SDKs.

Let’s assume we use a chaincode and a web application that exposes the business logic to our end customers (using a HLF SDK that implements a simple Web UI).

Consortia allows you to deploy your chaincodes/applications from a GIT/Docker repository. In order to ease the deployment you may integrate your private repository or use any public repository.

1. Integrate your source code repository (optional)

Here are the steps to integrate your source code repository provider (where your chaincode source code is managed)

You git provider may ask to grant access to your repositories. This is needed in order to deploy your chaincode on your peers. You may remove the access anytime by using your git provider management console (in case the access is revoked, you will not be able to deploy your chaincode with Consortia).

After you integrate your git repositories you may proceed with the chaincode deployment. The deployment is a multi step HLF chaincode deployment process that is simple and easy to perform/automate with Consortia.

2. Install your chaincode

The purpose of this step is to bring your chaincode on your peers. Usually the chaincode runs on peers managed and owned by participating network MSPs (MSPs owned and operated by your partners). The process of bringing the chaincode to all network peers is asynchronous and usually managed out-of-band between the participating partners.

To install a chaincode on your peers


Note

You may install multiple version of your chaincode on your peers and later on decide what version to instantiate.



Note

Under the Chaincode Deployment Layout section you may see the list of peers/channels where the selected chaincode version is installed/instantiated and the current status of the install process. Keep in mind you install a chaincode version on peers and instantiate it on channels.


After the installment of your chaincode is done, you may proceed with the chaincode deployment process and instantiate it on a channel.

3. Instantiate (upgrade) your chaincode

The HLF chaincode instantiation is a DLT transaction that is endorsed by the peers and ordered on the chosen channel through the related OSP.

Perform the following steps to instantiate your chaincode:


Note

Consortia will automatically set the endorsement policy based on the MSPs that are participating on the selected channel. You may always edit the policy if needed.



Note

You may instantiate a single chaincode version at a time. After the first instantiation of the chaincode you may upgrade it due to any reason (i.e. bugfix, endorsement policy upgrade, etc.).



Note

Under the Chaincode Deployment Layout section you may see the list of channels where the selected chaincode version is instantiated.


After the chaincode is deployed you may proceed further with the deployment of your application that will consume the chaincode and expose the business logic to your customers.

4. Deploy your web application

The HLF chaincode business logic is usually executed using the HLF provided SDKs. HLF community also provides best practice design elements for those applications.

Let’s assume you already have followed the best practices and you have your HLF application packaged and available on a docker repository.

Consortia may help you easily deploy your docker packaged web application and connect it to the HLF network nodes.

Perform the following steps to deploy your web application from a docker repository:


Note

You may deploy a sample chaincode and web application by following the steps.