2019 Summer Mentee Project Update: Scaling Real World Hyperledger Fabric Deployments

I got selected to the 2019 Hyperledger mentorship program for the project “Scaling Real World Hyperledger Fabric Deployments.” My mentors were Sasha and Nicola from Aid:Tech. Through this internship, I contributed several new features to “Nephos,” which is an open-source tool under Hyperledger Labs. Nephos helps to deploy and manage Hyperledger Fabric networks easily.

During my internship, I worked closely with the engineering team of Aid:Tech. My mentors, and I had several meetings to plan our tasks and to finalize the architectures. I made the following contributions to Nephos during my internship:

1. Stabilizing Nephos

During the first few weeks, I spent time on familiarizing myself with the relevant technologies and Nephos itself. During this time I fixed some known bugs in Nephos. Also during this phase, I improved the logging capability of Nephos through the native Python logger.

2. Support for multiple organizations

Nephos 0.3.X supported only one orderer organization and one peer organization. We wanted to allow the users to define as many organizations as they wanted. As some major changes had to be done that needed to be compatible with the future plans we have for Nephos, we discussed the architectures and changes in GitHub. Then we finalized the architecture and started working on it after an online meeting. Now, Nephos 0.4.X let multiple organizations to be defined.

3. Support for multiple channels

I also created a PR to let the user define multiple channels and precisely define which organizations belong to which channels so that, during the deployment, Nephos creates those channels and make the peers join the relevant channels. In order to achieve this, I also had to make changes to the “hlf-peer” helm charts in helm stable repository.

4. Support for Hyperledger Fabric 1.4

As Hyperledger Fabric 1.4 is the LTS version of Fabric, we made Nephos and the relevant helm charts support Fabric 1.4.

5. Support for TLS communication within nodes.

After supporting Fabric 1.4, we wanted to make sure that Nephos will work with RAFT ordering service, which is one the main feature we got by updating to Fabric 1.4. But, in order to support RAFT, we needed to support TLS communication between peers and orderers. I implemented this support, and now users can either use the TLS certificates generated by the cryptogen or they can ask Nephos to deploy a separate certificate authority to provide TLS certificates. In the latter case, Nephos will deploy a separate CA, generate all the relevant certificates, place the certificates in relevant pods and will use them for all the communication.

I hope to present my work at Hyperledger Global Forum 2020 in  Phoenix, Arizona. 

Experience gained

During my internship, I got a detailed understanding of how a Hyperledger Fabric network works, how to set it up, how to take advantage of its pluggable consensus model and how to make it secure. I also gained a lot of experience with Kubernetes and helm charts.

I have contributed to other open-source projects in the past, and Nepos is one of the most organized repositories I’ve seen. Working closely with my mentors, who built this open-source project from the ground up, gave me a lot of insights into how to effectively build and maintain an open-source project.

More details are available in my final project report.