Blockchain with Hyperledger Fabric
eBook - ePub

Blockchain with Hyperledger Fabric

Build decentralized applications using Hyperledger Fabric 2, 2nd Edition

Nitin Gaur, Anthony O'Dowd, Petr Novotny, Luc Desrosiers, Venkatraman Ramakrishna, Salman Baset

  1. 756 Seiten
  2. English
  3. ePUB (handyfreundlich)
  4. Über iOS und Android verfügbar
eBook - ePub

Blockchain with Hyperledger Fabric

Build decentralized applications using Hyperledger Fabric 2, 2nd Edition

Nitin Gaur, Anthony O'Dowd, Petr Novotny, Luc Desrosiers, Venkatraman Ramakrishna, Salman Baset

Angaben zum Buch
Buchvorschau
Inhaltsverzeichnis
Quellenangaben

Über dieses Buch

Learn to develop blockchain-based distributed ledgers and deploy a Hyperledger Fabric network with concrete exercises and examples

Key Features

  • Updated with the latest features and additions that come with Hyperledger Fabric 2
  • Write your own smart contracts and services using Java and JavaScript on a Hyperledger Fabric network
  • Dive into real-world blockchain challenges such as integration and scalability

Book Description

Blockchain with Hyperledger Fabric - Second Edition is a refreshed and extended version of the successful book on practical Hyperledger Fabric blockchain development. This edition includes many new chapters, alongside comprehensive updates and additions to the existing ones. Entirely reworked for Hyperledger Fabric version 2, this edition will bring you right up to date with the latest in blockchain. Using a real-world Trade Finance and Logistics example, with working code available on GitHub, you'll really understand both how and why Hyperledger Fabric can be used to maximum effect. This book is your comprehensive guide and reference to explore and build blockchain networks using Hyperledger Fabric version 2.

This edition of the book begins by outlining the evolution of blockchain, including an overview of relevant blockchain technologies. Starting from first principles, you'll learn how to design and operate a permissioned blockchain network based on Hyperledger Fabric version 2. You will learn how to configure the main architectural components of a permissioned blockchain network including Peers, Orderers, Certificate Authorities, Channels, and Policies. You'll then learn how to design, develop, package, and deploy smart contracts, and how they are subsequently used by applications. This edition also contains chapters on DevOps, blockchain governance, and security, making this your go-to book for Hyperledger Fabric version 2.

What you will learn

  • Discover why blockchain is a technology and business game changer
  • Set up blockchain networks using Hyperledger Fabric version 2
  • Understand how to create decentralized applications
  • Learn how to integrate blockchains with existing systems
  • Write smart contracts and services quickly with Hyperledger Fabric and Visual Studio Code
  • Design transaction models and smart contracts with Java, JavaScript, TypeScript, and Golang
  • Deploy REST gateways to access smart contracts and understand how wallets maintain user identities for access control
  • Maintain, monitor, and govern your blockchain solutions

Who this book is for

This book is designed in such a way that professionals from different areas including business leaders, technology leaders, blockchain application developers, and even beginners can benefit from it.

Häufig gestellte Fragen

Wie kann ich mein Abo kündigen?
Gehe einfach zum Kontobereich in den Einstellungen und klicke auf „Abo kündigen“ – ganz einfach. Nachdem du gekündigt hast, bleibt deine Mitgliedschaft für den verbleibenden Abozeitraum, den du bereits bezahlt hast, aktiv. Mehr Informationen hier.
(Wie) Kann ich Bücher herunterladen?
Derzeit stehen all unsere auf Mobilgeräte reagierenden ePub-Bücher zum Download über die App zur Verfügung. Die meisten unserer PDFs stehen ebenfalls zum Download bereit; wir arbeiten daran, auch die übrigen PDFs zum Download anzubieten, bei denen dies aktuell noch nicht möglich ist. Weitere Informationen hier.
Welcher Unterschied besteht bei den Preisen zwischen den Aboplänen?
Mit beiden Aboplänen erhältst du vollen Zugang zur Bibliothek und allen Funktionen von Perlego. Die einzigen Unterschiede bestehen im Preis und dem Abozeitraum: Mit dem Jahresabo sparst du auf 12 Monate gerechnet im Vergleich zum Monatsabo rund 30 %.
Was ist Perlego?
Wir sind ein Online-Abodienst für Lehrbücher, bei dem du für weniger als den Preis eines einzelnen Buches pro Monat Zugang zu einer ganzen Online-Bibliothek erhältst. Mit über 1 Million Büchern zu über 1.000 verschiedenen Themen haben wir bestimmt alles, was du brauchst! Weitere Informationen hier.
Unterstützt Perlego Text-zu-Sprache?
Achte auf das Symbol zum Vorlesen in deinem nächsten Buch, um zu sehen, ob du es dir auch anhören kannst. Bei diesem Tool wird dir Text laut vorgelesen, wobei der Text beim Vorlesen auch grafisch hervorgehoben wird. Du kannst das Vorlesen jederzeit anhalten, beschleunigen und verlangsamen. Weitere Informationen hier.
Ist Blockchain with Hyperledger Fabric als Online-PDF/ePub verfügbar?
Ja, du hast Zugang zu Blockchain with Hyperledger Fabric von Nitin Gaur, Anthony O'Dowd, Petr Novotny, Luc Desrosiers, Venkatraman Ramakrishna, Salman Baset im PDF- und/oder ePub-Format sowie zu anderen beliebten Büchern aus Computer Science & Cryptography. Aus unserem Katalog stehen dir über 1 Million Bücher zur Verfügung.

Information

Jahr
2020
ISBN
9781839216176

9

Network Operation and Distributed Application Building

In previous chapters, we established the foundations of a business network and application spanning multiple organizations and stakeholders:
  • In Chapter 4, Setting the Stage with a Business Scenario, we configured and ran a barebones trade network from a set of specifications
  • In Chapter 5, Designing Smart Contract Transactions and Ledger Data Structure, we built the core of a blockchain application in the form of a set of smart contracts that directly read and manipulate the ledgers that are the systems-of-record for your network
The bulk of the configuration and application logic development is done, but our task is far from finished.
As you can imagine, the contracts, which act on data used by multiple organizations, are sensitive pieces of code that ought to be accessible only via safe channels with built-in protections against misuse. Therefore, it is standard practice among blockchain developers to layer one or more applications above the contracts, exposing the contracts' capabilities in ways that provide adequate security and privacy safeguards. These applications, unlike smart contracts, can be engineered as typical enterprise applications using well-known technology stacks. They can also be integrated with existing enterprise applications used by organizations that participate in blockchain networks.
Unlike a smart contract, which acts on a shared backing store (ledger) whose state is held in consensus by network participants, the higher-layer enterprise applications don't necessarily have to act on behalf of the entire network. In fact, the various organizations and stakeholders within them may have unique and specific business logic requirements, requiring the development of different applications serving selected clientele. Therefore, a single blockchain network may end up exposing different ledger views and contract capabilities to different stakeholders. Further, these applications may run in enterprise security domains maintained independently by the different organizations. Collectively, though, the set of smart contracts and higher-layer applications can be viewed as a distributed application acting on a common data storage layer.
In this chapter:
  • We will learn how to build and operate a distributed Fabric application for the business entities that participate in our trade scenario:
    • We will recap the Hyperledger Fabric ledger setup and transaction pipelines
    • We will show how each step is performed using code and configuration samples
  • At the end of this process, you will understand how to:
    • Bootstrap network ledgers
    • Install contracts
    • Engineer applications as web services that can be exercised by users through commands on a terminal or from a web browser
  • We will learn how to build a production-grade ordering service that generates transaction blocks by consensus of a cluster of nodes running the Raft protocol
We will begin this chapter by discussing the nature of a multi-layered distributed Fabric application: first in generic terms, and subsequently using our trade scenario as an example. Later, we will demonstrate how to develop and bootstrap such an application to enable our trade scenario.

Stages in a Fabric network's life cycle

Before we dive into the details of application-building, it is important to first gain a broader perspective on how a Fabric network is created and bootstrapped in readiness for deploying and running applications, and what streams of developmental activities must be undertaken. Figure 9.1 illustrates these stages and activities from the perspectives of three groups of subjects: operators and maintainers, developers, and users:
  • Network setup and bootstrapping activities are classified into operations, which is the responsibility of network operators designated by their respective organizations or by the consortium. Operators will also typically oversee DevOps.
  • Development, which involves designing, writing, and testing application code, can occur before or concurrently with operations. The developers responsible for this are typically distinct from operators and do not need to know operational details, though they need to know the organizational and channel structure to write proper code.
  • Finally, the exercising of the applications' business logic is classified into runtime activities, and this is done by members and clients of the enterprises that belong to the network consortium.
Figure 9.1: A Fabric network's life cycle categorized into operational, developmental, and runtime stages
The operations stage (steps 1 to 4 in Figure 9.1) begins with the process of starting up individual components of a network (step 1), namely the peers belonging to designated organizations that share channel ledgers, ordering nodes (typically) belonging to their separate organizations, and nodes running Fabric CA servers and acting as CAs for their respective organizations. We demonstrated this process in Chapter 4, Setting the Stage with a Business Scenario.
Next, we set up channels and associate each network peer with one or more channels (step 2). We walked through an example of defining a channel's configuration and creating the artifacts necessary to start up those channels in Chapter 4, Setting the Stage with a Business Scenario. In this chapter, we will see how to create channels and bootstrap their ledgers (or chains). Smart contract development (step 1a) can occur together with the channel definition and setup; since contracts running on different channels may need to communicate at runtime, the contract developers must know channel names and organizational affiliations beforehand.
Having completed Chapter 5, Designing Smart Contract Transactions and Ledger Data Structure, you should already know how to implement a contract. Once the channels are set up, each contract must be installed and initialized on a given channel (step 3), which we will see how to do later in this chapter. Finally, the higher-layer applications can be started (step 4); these can be developed (step 3a) at any point in time using knowledge of the API offered by each contract, but must be started for users to complete this exercise.
At the end of the operations stage, a distributed applica...

Inhaltsverzeichnis

Zitierstile für Blockchain with Hyperledger Fabric

APA 6 Citation

Gaur, N., O’Dowd, A., Novotny, P., Desrosiers, L., Ramakrishna, V., & Baset, S. (2020). Blockchain with Hyperledger Fabric (2nd ed.). Packt Publishing. Retrieved from https://www.perlego.com/book/2059666/blockchain-with-hyperledger-fabric-build-decentralized-applications-using-hyperledger-fabric-2-2nd-edition-pdf (Original work published 2020)

Chicago Citation

Gaur, Nitin, Anthony O’Dowd, Petr Novotny, Luc Desrosiers, Venkatraman Ramakrishna, and Salman Baset. (2020) 2020. Blockchain with Hyperledger Fabric. 2nd ed. Packt Publishing. https://www.perlego.com/book/2059666/blockchain-with-hyperledger-fabric-build-decentralized-applications-using-hyperledger-fabric-2-2nd-edition-pdf.

Harvard Citation

Gaur, N. et al. (2020) Blockchain with Hyperledger Fabric. 2nd edn. Packt Publishing. Available at: https://www.perlego.com/book/2059666/blockchain-with-hyperledger-fabric-build-decentralized-applications-using-hyperledger-fabric-2-2nd-edition-pdf (Accessed: 15 October 2022).

MLA 7 Citation

Gaur, Nitin et al. Blockchain with Hyperledger Fabric. 2nd ed. Packt Publishing, 2020. Web. 15 Oct. 2022.