Blockchain is a distributed ledger system where nodes work together to validate transactions in a coordinated fashion without a central authority. It allows for decentralized consensus through mechanisms like proof-of-work. The main challenges in distributed systems are coordination between nodes and achieving fault tolerance. The CAP theorem states that a distributed system cannot achieve consistency, availability, and partition tolerance simultaneously. Blockchain sacrifices consistency for availability and partition tolerance. It uses elements like addresses, transactions, blocks, and consensus mechanisms like proof-of-work to securely and immutably record transactions on the distributed ledger.
2. Understanding Blockchain Technology
Understanding distributed systems is essential in order to
understand blockchain technology.
Blockchain at its core is a distributed system, more precisely is a dece
Distributed systems are a computing paradigm whereby two or
more nodes work with each other in a coordinated fashion in
order to achieve a common outcome
3. Distributed Systems
In a distributed system a node is an individual player
Nodes are capable of sending messages to and from each
other
Nodes can be honest, faulty or malicious and have their own
memory and processor
A node that can exhibit an arbitrary or malicious behavior is
also known as a Byzantine node.
A Byzantine node can be detrimental to the operation of the
network because of its behavior
4. Distributed Systems and the Blockchain Technology
The main challenge in distributed systems design is coordination
between nodes and fault tolerance. Even if some of the nodes
become faulty the d.s. should continue to work flawlessy in order
to achieve the desired results.
5. Design Challenges in Distributed Systems and
CAP Theorem
• Any distributed system cannot have Consistency,
Availability, and Partition tolerance simultaneously
6. Cap Theorem and the Blockchain
• It seems that the CAP theorem is violated in blockchain but this is
not true.
• In blockchain the Consistency is sacrificed in favor of Availability and
Partition tolerance
• In the most famous blockchain application, bitcoin, Consistency is
not achieved simultaneously with Partition Tolerance and Availability
• In Bitcoin blockchain consistency is achieved as a result of validation
from multiple nodes over time.
• For this purpose the concept of mining was introduced, which
facilities the achievement of consensus through a mechanism called
PoW (Proof of Work)
7. Introduction to Blockchain Technology
• The blockchain technology definition highly depends on how you
look at it. Business view or technical view.
• The blockchain technology is a peer-to-peer distributed ledger that
is cryptographically secure, append only, immutable and up-
dateable only via consensus among peers
• Different consensus mechanisms allow the nodes to agree on the
new state of the distributed ledger.
8. Blockchain technology under different
perspectives:network
Blockchain is a layer of a
distributed peer-to-peer
network running on top of the
Internet, just like SMTP,
HTTP, or FTP running on top
of TCP/IP.
9. Blockchain technology under different
perspectives: business
• The Blockchain technology as a platform whereby
peers can exchange values using transactions
without the need for a central trusted arbitrator.
• A powerful concept which has a tsunamic potential
as it allows for decentralized consensus where no
central authority is needed.
10. Blockchain technology under different
perspectives: data structure
• Blockchain is a data structure just like a linked list that
uses hash pointers instead of normal pointers. Hash
pointers are used to point to the previous block.
11. Blockchain Elements
• Addresses are unique identifiers that are used in a transaction
on the blockchain to denote senders and recipients.
• A transaction is the fundamental unit of a blockchain and
represents a transfer of value from one address to another.
• A block = multiple transactions, previous block hash (hash
pointer), timestamp, and nonce.
• A node in a blockchain network can have different roles. It can
propose and validate transactions and perform mining. Make
simple payments etc..
• A smart contract is a program that runs on top of the
blockchain and encapsulate the business logic to be executed
when certain conditions are met. A very desirable feature due
to the flexibility and power it provides to
12. Features of a blockchain
• Distributed consensus enables a blockchain to present a single
version of the truth without the requirement of a central authority
• Transactions posted from nodes are verified based on a
predetermined set of rules. Only valid transactions are selected for
inclusion in a block
• A blockchain is a platform where programs can run that execute
business logic on behalf of the users, the so called smart contracts
• Blockchain enables the transfer of value between its users via
tokens. Tokens can be thought of as a carrier of value
• This is an optional feature depending on the type of blockchain
used. A blockchain can generate cryptocurrency as an incentive to
its miners who validate the transactions and spend resources in
order to secure the blockchain.
14. Consensus Mechanisms
• The choice of the consensus mechanism is conditioned by the
type of blockchain.
• Two types of consensus mechanisms
➢ Proof-based
➢ Votes based
15. Consensus Mechanisms
• Proof of work
• Proof of stake
• Delegated Proof of Stake
• Proof of Elapsed Time
• Deposit-based consensus
• Proof of importance
• Federated consensus or federated Byzantine consensus
16. Consensus Mechanisms and Performance
Votes based Proof based
Speed Good Poor
Scalability Moderate Good
Finality Good Poor
17. Blockchain Demo
There is a great demo showing how a blockchain
works and in particular it explains concepts like
cryptography, hashing of a transaction, elements of a
block and how they are appended to the blockchain
etc..
The demo can be found here
https://anders.com/blockchain/hash.html
18. Example – Bitcoin
• The Bitcoin blockchain: understanding the
blockchain technology through its most famous
application, bitcoin.