Lecture 14 - Blockchain Consensus-I
Lecture 14 - Blockchain Consensus-I
§ PoW
§ PoS
§ Metrics of Consensus
2
Outline of Lecture 15
§ PoW
§ PoS
§ Metrics of Consensus
3
Proof-of-Work
Proof of Work (PoW)
ü Consensus
4
Proof-of-Work
Proof of Work (PoW)
ü Consensus
When talking about consensus in a distributed environment,
two types of nodes generally involved:
5
Proof-of-Work
Proof of Work (PoW)
ü Consensus
The system has to operate properly even if any failure
occurs. There are two types of failures occur:
8
Proof-of-Work
Proof of Work (PoW)
ü Proof of Work (PoW) Consensus
Ø The higher the hash rate, the higher the chances to solve
the PoW cryptographic puzzle.
Ø The node that solves the PoW puzzle will be the winner
and thus will be able to add block to the blockchain and
deserve the reward.
10
Proof-of-Work
Proof of Work (PoW)
ü PoW Nodes
11
Proof-of-Work
Proof of Work (PoW)
ü PoW Winning Probability
13
Proof-of-Work
Proof of Work (PoW)
ü Example of PoW Consensus Algorithm
Ø PoW has a long latency issue, i.e., nodes take time to validate
transactions.
15
Proof-of-Work
Proof of Work (PoW)
ü Fault-tolerant of PoW
§ PoW
§ PoS
§ Metrics of Consensus
18
Proof of Stake
Proof of Stake (PoS)
ü PoS Main Idea
The higher the stake a node has, the higher the chances to
select that node as a winning miner node.
19
Proof of Stake
Proof of Stake (PoS)
ü PoS Advantages
20
Proof of Stake
Proof of Stake (PoS)
ü PoS Winner
22
Proof of Stake
Proof of Stake (PoS)
ü Issues in PoS
24
Proof of Stake
Proof of Stake (PoS)
ü Issues in PoS
26
Outline of Lecture 15
§ PoW
§ PoS
§ Metrics of Consensus
27
Metrics of Consensus
Metrics of Consensus
ü Metrics
Performance and scalability of IT systems have always
been the key non-functional metrics that are used to
gauge a blockchain consensus.
1. Performance
Ø Transaction Throughput
Ø Block Confirmation Time
2. Scalability
28
Metrics of Consensus
Metrics of Consensus
ü Transaction Throughput
where “Block Size” is the size of the block and varies from blockchain
to blockchain, and “Block Time” is the time required to add a block to
the blockchain – average.
30
Metrics of Consensus
Metrics of Consensus
ü Block Confirmation Time
35
Metrics of Consensus
Metrics of Consensus
ü Example
Solution:
Off-chain solutions:
built on top of the main blockchain and handle most of the
transactions. (Sidechains, Payment Channels, etc.)
37