Book Image

Blockchain Development with Hyperledger

By : Salman A. Baset, Luc Desrosiers, Nitin Gaur, Petr Novotny, Anthony O'Dowd, Venkatraman Ramakrishna, Weimin Sun, Xun (Brian) Wu
Book Image

Blockchain Development with Hyperledger

By: Salman A. Baset, Luc Desrosiers, Nitin Gaur, Petr Novotny, Anthony O'Dowd, Venkatraman Ramakrishna, Weimin Sun, Xun (Brian) Wu

Overview of this book

Blockchain and Hyperledger are open source technologies that power the development of decentralized applications. This Learning Path is your helpful reference for exploring and building blockchain networks using Ethereum, Hyperledger Fabric, and Hyperledger Composer. Blockchain Development with Hyperledger will start off by giving you an overview of blockchain and demonstrating how you can set up an Ethereum development environment for developing, packaging, building, and testing campaign-decentralized applications. You'll then explore the de facto language Solidity, which you can use to develop decentralized applications in Ethereum. Following this, you'll be able to configure Hyperledger Fabric and use it to build private blockchain networks and applications that connect to them. Toward the later chapters, you'll learn how to design and launch a network, and even implement smart contracts in chain code. By the end of this Learning Path, you'll be able to build and deploy your own decentralized applications by addressing the key pain points encountered in the blockchain life cycle. This Learning Path includes content from the following Packt products: • Blockchain Quick Start Guide by Xun (Brian) Wu and Weimin Sun • Hands-On Blockchain with Hyperledger by Nitin Gaur et al.
Table of Contents (25 chapters)
Title Page
Copyright
About Packt
Contributors
Preface
Index

Defining the terms – what is a blockchain?


At a technical level, a blockchain can be defined as an immutable ledger for recording transactions, maintained within a distributed network of mutually untrusting peers. Every peer maintains a copy of the ledger. The peers execute a consensus protocol to validate transactions, group them into blocks, and build a hash chain over the blocks. This process forms the ledger by ordering the transactions as is necessary for consistency. Blockchain has emerged with bitcoin (http:// bitcoin.org/) and is widely regarded as a promising technology to run trusted exchanges in the digital world.

A blockchain supporting a cryptocurrency is public, or permissionless, in the sense that anyone can participate without a specific identity. Such blockchains typically use a consensus protocol based on proof of work (PoW) and economic incentives. In contrast, permissioned blockchains have evolved as an alternative way to run a blockchain between a group of known, identified participants. A permissioned blockchain provides a way to secure interactions between a group of entities who share a mutual goal but don't fully trust each other, such as businesses that exchange funds, goods, or information. A permissioned blockchain relies on the identities of its peers, and in so doing can use the traditional Byzantine-fault tolerant (BFT) consensus. BFT is a protocol that has been widely used in IT solutions to reach a consensus on the state of faulty nodes of a network. This protocol is based on the Byzantine General's Problem, whereby a group of general need to reach a consensus on their strategy but one of them maybe treacherous.

Blockchains may execute arbitrary, programmable transaction logic in the form of smart contracts, as exemplified by Ethereum (http://ethereum.org/). The scripts in bitcoin were predecessors of this concept. A smart contract functions as a trusted, distributed application and gains its security from the blockchain and underlying consensus among its peers.

Discerning permissions from a permissionless blockchain is vital for enterprises looking to utilize the blockchain platform. The use case dictates the choice of technology, which depends on consensus systems, governance models, data structure, and so on. With permissioned blockchains, we can do some of the things we already do but in an incrementally better way, which can be significant. In the chart that follows, you can see how a consortium of banks could use Hyperledger, a type of permissioned blockchain, for clearing and settlement without relying on a central clearing house:

Clearing house have been created because banks do not fully trust each other and thus as the intermediary between trades, reduces the risk the one party does not honor his terms leads to a never-ending debate around permissioned versus permissionless blockchains, and while this chapter will not address the debate, blockchain can present a way to either transform or disrupt the current business and business models. Most use cases in regulated industries embark on permissioned blockchain models.

This is due to regulatory requirements and the economic viability of transaction processing, and while permissionless blockchains provide a platform for new business models such as Peer-to-Peer (P2P) transactions and disintermediation-led models, by definition permissionless blockchain architecture relies on a very compute-intensive compute model to ensure transactional integrity. Regardless of the choice in blockchain models, blockchain provides a lot of possibilities for transformation and disruption.

Blockchain has extraordinary potential as a technology platform. In the enterprise, blockchain can provide:

  • A design approach that keeps transaction data, value, and state inherently close to the business logic
  • Secure execution of business transactions, validated through a community, in a secure process that facilities the trust and robust transaction processing that are foundational to blockchain
  • An alternative, permissioned technology that conforms to existing regulations

Note

Blockchain promises to solve longstanding industry concerns—and this is where its potential can really be seen, with issues such as modernizing financial and trade systems, and speeding up securities and trade settlements.