Table of contents
Recap
Last week we defined Nakamoto consensus as :
A consensus mechanism that states that the valid chain is the longest chain with the most accumulated Proof-of-Work.
We also elaborated on
- Forks &
- Orphans
Let us retrace the steps from initiation to inclusion of a transaction in a block :
- Transactions are initiated between counter-parties
- These new transactions are broadcast to all the nodes in the network
- Each node collects these transactions and clubs them into a block
- The miner nodes work on finding proof-of-work solution for their blocks
- When the proof-of-work solution is found, it is broadcast to all the nodes in the network
- Nodes check if all the transactions within these blocks are valid & not double spent & then these blocks are accepted.
- The nodes then move on to work on the next block by using the hash of the previous block as the previous hash.
- The blocks within the longest chain are considered to be valid & the nodes will keep on working to extend it.
Types of Blockchain
This week we will explore blockchain classifications based on permission.
Now, what do we mean by "permission"?
It means access given to nodes to send, read & validate transactions in the blockchain network. They can be given full access like in a public blockchain where every node can read, send or validate transactions or restricted access like in a consortium or private blockchain. Let us dive deep into each of them.
There are three types of Blockchains based on permission as below :
- Public Blockchain
- Consortium Blockchain
- Private Blockchain
Public Blockchain
A Public blockchain is a blockchain where any node in the network can read, send transactions, include and validate them if they are valid. Any node can also participate in the consensus process - to agree on the blocks & transactions. It is fully decentralized and all transactions are visible to everyone on the network. E.g., Bitcoin & Ethereum blockchains are public blockchains.
Due to the decentralized & public nature of the network, public blockchains are secured using crypto economics - which means there are incentives to keep the network safe by using hashes, proof of work etc as there is no centralized entity in control of the network.
In summary,
- Blocks are validated one after another & cannot be modified subsequently (immutable)
- The network is open for all and new participants
- All nodes are involved in validating the blocks
- All nodes can read the data contained in the blocks
Consortium Blockchain
A Consortium blockchain is a blockchain where the consensus protocol is controlled by a pre-selected set of nodes. The right to read the blockchain may be public or restricted to a few participating nodes.
A consortium blockchain is managed by more than one organization. So it is not centralized in nature. It is "partially decentralized". A consortium blockchain has a validator node that can validate, initiate & receive transactions & member nodes who can only initiate & receive transactions.
In Summary,
- These are open to the public but not all data is available to all nodes. These are "Partially Decentralized"
- Blocks are validated one after another & cannot be modified subsequently (immutable)
- New nodes are allowed based on consensus from existing participants that is existing participants should agree to allow new nodes in
- Blocks are validated based on predefined rules
Private Blockchain
A fully private blockchain is a blockchain where write permissions are kept centralized to one organization. Read permissions may be public or restricted to an arbitrary extent. Such blockchains are restricted to completely trusted entities where the central node can subsequently modify transactions, manage the rights to access & modify the database.
In Summary,
- Blocks are validated by a central node & can be subsequently modified
- New nodes are chosen by this central node
- Blocks are validated by the central node
Now, why are there different classifications of blockchain if the central tenet of blockchain is decentralization & trust-less access to financial services? Why do we need consortium or private blockchains?
A consortium blockchain is useful where multiple organizations who cooperate together on a venture join together to maintain the system as nodes. Let us take the example of the logistics industry :
Image by Gerd Altmann from Pixabay
Image by Gerd Altmann from Pixabay
What is logistics ?
Logistics is widely known as the process of coordinating & moving resources, such as equipment, food, liquids, inventory, materials and people from one location to the storage of the desired destination.
It is the management of the flow of goods from one point of origin to the point of consumption to meet the requirements of customers.
(Source of definition here)
Logistics involves moving items from source to destination and involves a multitude of partners :
- The manufacturer
- Logistics company to transport goods or equipment from manufacturing unit to port of departure
- Ship or aircraft to transport the goods or equipment to destination country
- Logistics company to transport goods from port of destination to wholesaler or to end retailer
- End retailer / customer
- Banks involved in financing at various stages of moving the goods
Now, each of them wants to keep track of the goods, especially the end retailer or customer. If all of them share a common ledger where entries reflect the stage of journey of the goods, that would save on
Cost of maintaining multiple books of accounts or individual ERP systems
Reconciliation costs &
They are immutable and trust-less (meaning companies can trust the entries without trusting the entities passing those entries)
Each of the above entities can be a node in a consortium blockchain which is managed by the entities together with consensus protocols.
The below visualization makes it clear :
Such a blockchain cannot be a public blockchain as any unrelated party can also view the goods in transit or any other information which may be confidential. Thus, the access permissions can be provided to any or all of the interested parties depending on their requirements. This is a good use case of a consortium blockchain among many others.
What about private blockchains? When would we need those ?
A private blockchain is maintained by an organization who has full control over the blockchain protocols and consensus algorithms. This organization decides who can join the network & their access rights.
Imagine a company with offices or branches in different countries. The Head office can be the central node which decides on the consensus & other protocols while the other branches can have read or write access depending on the requirements. The read access can also be restricted in a way that each branch can access its ledgers only.
Now, which one is better & what are the considerations to choose one over the other?