Back to Course

Session 4.4 - Hyperledger Fabric Architecture

Analyze enterprise blockchain architecture

Module 4 45 minutes

Learning Objectives

  • Understand Hyperledger Fabric's modular architecture
  • Analyze the roles of peers, orderers, and certificate authorities
  • Explore channels and private data collections
  • Compare Fabric with public blockchain architectures
  • Design enterprise blockchain solutions using Fabric

Hyperledger Fabric Overview

Enterprise-Grade Blockchain

Hyperledger Fabric is a permissioned blockchain framework designed for enterprise use, offering modularity, scalability, and privacy.

Permissioned

Known identities and controlled access

Modular

Pluggable consensus and membership services

Private

Confidential transactions and data

Introduction to Hyperledger Umbrella

What is Hyperledger?
  • Hyperledger is an open-source umbrella project hosted by the Linux Foundation (launched in 2015).
  • It provides a suite of frameworks, tools, and libraries for developing enterprise-grade blockchain and distributed ledger technologies (DLTs).
  • Focus: Permissioned (private) blockchains for businesses, unlike public blockchains (Bitcoin, Ethereum).
Goals of Hyperledger
  1. Provide Modular Frameworks: Pluggable consensus, identity, and smart contract models.
  2. Support Enterprise Use Cases: Supply chain, healthcare, trade finance, identity management, IoT, etc.
  3. Foster Collaboration: Global consortium of tech companies, enterprises, startups, and academics.
  4. Promote Interoperability & Standards: Build reusable components (cryptography, identity, interoperability).
Components Under Hyperledger Umbrella
Frameworks (DLT platforms)
  • Hyperledger Fabric: Modular, permissioned blockchain with channels & MSP.
  • Hyperledger Sawtooth: Modular, scalable, PoET consensus, used in IoT.
  • Hyperledger Besu: Ethereum-compatible client for both public & private use.
  • Hyperledger Iroha: Lightweight, mobile/IoT-focused blockchain.
  • Hyperledger Indy: Purpose-built for decentralized identity (DID).
Tools
  • Explorer: Monitor blockchain activity via web UI.
  • Caliper: Benchmarking framework for blockchains.
  • Cello: Blockchain-as-a-Service (BaaS) deployment/management.
  • Quilt: Implements Interledger Protocol (ILP) for cross-chain payments.
Libraries
  • Ursa: Shared cryptographic library.
  • Aries: Identity & communication layer (works with Indy).
  • Transact: Shared transaction execution engine.
Why an "Umbrella"?
  • Instead of being a single blockchain platform, Hyperledger acts as an umbrella project hosting many independent but related sub-projects.
  • This allows enterprises to choose the right framework or tool for their specific use case.
  • Shared libraries (like Ursa and Aries) reduce duplication and ensure consistent standards across projects.
The Hyperledger Umbrella is:
  • A collaborative open-source initiative by the Linux Foundation.
  • Provides multiple blockchain frameworks (Fabric, Sawtooth, Besu, Iroha, Indy).
  • Offers tools and libraries for deployment, monitoring, interoperability, identity, and cryptography.
  • Designed for enterprise-grade, permissioned blockchain solutions.

Hyperledger Ecosystem Block Diagram

Frameworks
Hyperledger Fabric
Modular enterprise blockchain
Hyperledger Sawtooth
IoT/supply chain with PoET
Hyperledger Iroha
Lightweight for mobile/IoT apps
Hyperledger Besu
Ethereum client (public/permissioned)
Hyperledger Indy
Decentralized identity (DID)
Tools
Hyperledger Explorer
Web UI for monitoring
Hyperledger Caliper
Benchmarking framework
Hyperledger Cello
Blockchain-as-a-Service (BaaS)
Libraries
Hyperledger Quilt
Interledger Protocol (ILP) interoperability
Hyperledger Ursa
Shared cryptographic library
Hyperledger Aries
Peer-to-peer identity and messaging
Hyperledger Transact
Transaction execution engine
Ecosystem Purpose
Frameworks build blockchain networks • Tools manage/monitor/benchmark • Libraries provide crypto & identity backbone

Hyperledger Ecosystem Overview

The Hyperledger ecosystem is a modular set of blockchain frameworks, tools, and libraries designed for enterprise use cases.

1. Frameworks (Core Blockchains)
  • Hyperledger Fabric 🟢
    Permissioned blockchain platform. Modular, pluggable consensus, channels for private data. Widely used in supply chain, finance, healthcare.
  • Hyperledger Sawtooth 🟠
    Focus on modularity and scalability. Supports Proof of Elapsed Time (PoET) consensus. Used in IoT and supply chain.
  • Hyperledger Iroha 🔵
    Simple, lightweight DLT. Designed for mobile and IoT apps. Strong emphasis on simple API and easy integration.
  • Hyperledger Besu 🟣
    Ethereum client written in Java. Supports both permissioned and public Ethereum. Enterprise use for tokenization and DeFi.
  • Hyperledger Indy 🟡
    Purpose-built for decentralized identity (DID). Provides verifiable credentials & self-sovereign identity. Used for identity management systems.
2. Tools (Support & Management)
  • Hyperledger Explorer 🔍
    Web-based UI to view blockchain activities. Monitor transactions, blocks, and smart contracts.
  • Hyperledger Caliper ⚖️
    Benchmarking tool for blockchain frameworks. Measures throughput, latency, resource usage.
  • Hyperledger Cello ⚙️
    Blockchain-as-a-Service (BaaS). Automates deployment & management of blockchain networks.
  • Hyperledger Quilt 🪢
    Provides Interledger Protocol (ILP) implementation. Enables interoperability between ledgers.
  • Hyperledger Ursa 🔐
    Shared cryptographic library for all frameworks. Reduces duplication, ensures secure cryptographic primitives.
3. Libraries
  • Hyperledger Aries 🤝
    Framework for peer-to-peer identity and messaging. Works with Indy for verifiable credentials.
  • Hyperledger Transact 📦
    Transaction execution platform. Provides a shared smart contract engine. Used in Sawtooth and other frameworks.
Purpose of the Ecosystem
  • Fabric: Modular enterprise blockchain.
  • Sawtooth: IoT/supply chain with PoET.
  • Iroha: Simple blockchain for mobile apps.
  • Besu: Ethereum-compatible enterprise client.
  • Indy: Identity management.
  • Aries + Ursa: Identity and crypto backbone.
  • Caliper, Cello, Explorer, Quilt: Monitoring, benchmarking, BaaS, interoperability.

Core Components

Network Participants

Fabric networks consist of multiple types of nodes, each with specific roles and responsibilities.

Peer Nodes
  • Endorsing Peers: Execute and endorse transactions
  • Committing Peers: Validate and commit blocks
  • Anchor Peers: Cross-organization communication
  • Leader Peers: Distribute blocks within organization
Orderer Nodes
  • Transaction Ordering: Sequence transactions
  • Block Creation: Package transactions into blocks
  • Consensus Service: Ensure ordering agreement
  • Channel Management: Create and manage channels
Certificate Authority (CA)
  • Identity Management: Issue digital certificates
  • Enrollment: Register network participants
  • Revocation: Revoke compromised certificates
  • Attribute Certificates: Role-based permissions
Client Applications
  • Transaction Submission: Propose transactions
  • SDK Integration: Use Fabric SDKs
  • Query Operations: Read ledger state
  • Event Listening: Monitor blockchain events

Transaction Flow

Execute-Order-Validate Architecture

Fabric uses a unique three-phase transaction model that separates execution from ordering and validation.

Transaction Lifecycle
1. Execute

Client submits proposal to endorsing peers

2. Order

Orderer sequences endorsed transactions

3. Validate

Peers validate and commit to ledger

Phase Participants Actions Output
Execute Client, Endorsing Peers Simulate transaction, generate read/write sets Endorsed proposal response
Order Client, Orderer Submit transaction, create ordered blocks Ordered transaction blocks
Validate All Peers Validate endorsements, check read/write conflicts Updated ledger state

Channels and Privacy

Multi-Channel Architecture

Channels provide data isolation and privacy by creating separate ledgers for different participant groups.

Channel Benefits
  • Data Isolation: Separate ledgers per channel
  • Selective Participation: Invite-only membership
  • Confidentiality: Private business logic
  • Scalability: Parallel transaction processing
Private Data Collections
  • Subset Privacy: Share with specific organizations
  • Hash on Ledger: Proof without revealing data
  • Purging: Automatic data deletion
  • Endorsement: Private data endorsement policies

Smart Contracts (Chaincode)

Chaincode Development

Smart contracts in Fabric are called chaincode and can be written in Go, Node.js, or Java.

Chaincode Lifecycle
  1. Package: Bundle chaincode
  2. Install: Deploy to peers
  3. Approve: Organization approval
  4. Commit: Activate on channel
  5. Invoke: Execute functions
Endorsement Policies
  • AND Policy: All specified orgs must endorse
  • OR Policy: Any specified org can endorse
  • Threshold: Minimum number of endorsements
  • Custom Logic: Complex endorsement rules
Hyperledger Fabric Architecture — Detailed Diagram

Hyperledger Fabric Architecture — Detailed Diagram

Application / Client Layer
Client SDKs (Node.js, Java, Go, Python)
Submit transaction proposals
Collect endorsements from peers
Peers
Sends endorsed tx to ordering service
Maintain ledger & world state
Endorsing Peers: simulate & sign tx proposals
Committing Peers: validate and append blocks
Anchor Peers: cross-org communication
Ordering Service
Orders endorsed transactions chronologically
Batches into blocks
Consensus mechanisms: Raft, Kafka (deprecated)
Delivers blocks to all peers
Ledger
Blockchain log (immutable, append-only)
World State DB (LevelDB or CouchDB)
Stores latest key-value pairs
Chaincode (Smart Contracts)
Business logic for applications
Runs in Docker container for isolation
Written in Go, Node.js, Java
Executes during endorsement simulation
Membership Service Provider (MSP)
Identity and access management
Issues X.509 digital certificates
Defines roles: clients, peers, orderers, admins
Channels
Private communication subnets
Allow consortium members to transact privately

Execution Flow

Step 1: Client submits tx proposal via chaincode → Collect endorsementsOrdering Service (batch txs into blocks)

Step 2: Distributed to peers (World State + Blockchain)MSP ensures proper identities/rolesChannels maintain private ledgers

Hyperledger Fabric Architecture

Application / Client Layer
  • Uses SDKs (Node.js, Java, Go, Python)
  • Submits transaction proposals to endorsing peers
  • Collects endorsements → forwards to ordering service
Peers
  • Endorsing Peers: Simulate transaction, run chaincode, sign results
  • Committing Peers: Validate endorsements, update ledger
  • Anchor Peers: Enable cross-organization communication
Ordering Service
  • Orders endorsed transactions chronologically
  • Batches into blocks
  • Consensus: Raft (modern), Kafka (legacy)
  • Delivers blocks to all peers
Ledger
  • Blockchain log: Immutable, append-only list of transactions
  • World State DB: Key-value store (LevelDB/CouchDB) for latest values
Chaincode (Smart Contracts)
  • Business logic, written in Go, Node.js, or Java
  • Runs in Docker containers (isolation)
  • Executed during the endorsement phase
Membership Service Provider (MSP)
  • Manages identities and roles using X.509 certificates
  • Ensures only authorized entities participate
  • Defines clients, peers, orderers, and admins
Channels
  • Private communication subnets within the network
  • Each channel has its own ledger and chaincode
  • Ensures data confidentiality between subsets of participants
Execution Flow Summary
  1. Client sends proposal → endorsing peers simulate & sign
  2. Endorsements collected → sent to ordering service
  3. Ordering service batches tx → creates block
  4. Peers validate block (endorsement policy + MVCC check)
  5. Ledger updated (blockchain + world state)
  6. MSP enforces identity and permissions
  7. Channels ensure private transactions for consortium members

Fabric vs Public Blockchains

Aspect Hyperledger Fabric Public Blockchains (Ethereum)
Access Permissioned, known identities Permissionless, anonymous
Consensus Pluggable (Raft, PBFT) Proof of Work/Stake
Privacy Channels, private data Public by default
Performance High throughput (1000+ TPS) Lower throughput (15-45 TPS)
Governance Consortium governance Community governance
Use Cases Enterprise, B2B, supply chain DeFi, public applications

Enterprise Use Cases

Supply Chain
  • Walmart: Food traceability
  • Maersk: Shipping and logistics
  • De Beers: Diamond provenance
  • Everledger: Luxury goods authentication
Financial Services
  • JPMorgan: Trade finance
  • HSBC: Letter of credit
  • IBM Food Trust: Food safety
  • TradeLens: Global trade platform

Summary

Key Takeaways
  • Fabric's modular architecture enables enterprise-grade blockchain solutions
  • Execute-Order-Validate model provides better performance and flexibility
  • Channels and private data collections ensure data privacy and confidentiality
  • Permissioned networks offer better governance and compliance
  • Suitable for B2B use cases requiring privacy and high throughput

What's Next?

Next, we'll explore Identity & Policies in enterprise blockchain systems.