The overall architecture of the blockchain includes six layers: data layer, network layer, consensus layer, incentive layer, contract layer, and application layer.
Data layer
The underlying dependence of all blockchain technologies is also the essence of blockchain.
Network Layer
The part that carries out point-to-point transactions and broadcast multicast ensures the smooth progress of transactions and transaction confirmations. It is precisely because of the point-to-point transaction characteristics of the blockchain that data transmission is dispersed among various nodes. The destruction of some nodes or networks will have little impact on other parts.
Consensus layer
In order to quickly unify the data of each node in the blockchain network and ensure the consistency of data across the entire network. Consensus algorithms are basically divided into proof type, Byzantine type, traditional consensus type and hybrid type. The POW (proof of work) mechanism involved in the introduction of Bitcoin before is a typical proof type consensus mechanism. However, the cost of the POW consensus algorithm is too high, and blockchain applications have now begun to gradually abandon the POW consensus algorithm and turn to other consensus algorithms.
Contract level
An interface for writing executable code provided to the outside world based on the underlying technology, which is where the smart contract resides. Smart contracts are pieces of code that can be stored in the blockchain. They can be triggered by transactions on the blockchain. The triggered code can read data from the blockchain or write data to the blockchain. To facilitate the use of blockchain platforms to develop customized practical applications.
Application layer
It can encapsulate various application scenarios of the blockchain. For example, various applications built on Ethereum include the Ethereum cat game (CryptoKittes), the open source developer incentive network (Giten), and the trading platform for betting on real-world events (Veil). wait.