[A web3 concept every day] Classification of consensus mechanisms

People who don’t understand the consensus mechanism must have this question: Why are there so many consensus mechanisms?

As mentioned earlier, the consensus mechanism is to solve the "trust problem", that is, to make everyone believe that something really happened. Returning to technology, it is actually to allow the distributed system to reach a consistent state, but this is not the only characteristic of the distributed system. Generally speaking, distributed systems have several most important characteristics: consistency, availability, partition tolerance, liveness, scalability, etc. However, according to the FLP theorem and the CAP theorem, there is no way for a distributed system to have consistency and high availability at the same time, which means that the design of all consensus mechanisms must make a trade-off.

Therefore, current projects will basically make some innovations at the consensus mechanism level to better adapt to actual needs and application scenarios. But generally speaking, there are standards for the classification of consensus mechanisms.

The simplest one is classified based on participation rights. Consensus mechanisms that require authorization to participate are often used in private chains and consortium chains, such as PBFT; consensus mechanisms that everyone can participate without authorization are used in public chains, such as PoW.

Secondly, it can be classified according to resource types, such as computing resources such as PoW, pledged assets such as PoS, storage space such as PoC (Proof of Space/Storage), etc. This is also the consensus mechanism type most commonly used in public chains.

Of course, it can also be classified according to the strength of consistency. Strong consistency such as Paxos, Raft, PBFT, and non-strong consistency such as PoW, PoS, etc.

It can also be classified according to the fault tolerance types we talked about before, such as those that can tolerate crash failures but cannot tolerate Byzantine faults, such as Paxos, VR, etc.; there are also those that can tolerate malicious nodes and malicious behaviors, such as PBFT, PoW, PoS, etc.

Finally, it can also be classified according to finality. The mechanism that is irreversible after the decision is executed is represented by PBFT; the mechanism that is reversible within a certain period of time after the decision is executed, but as time goes by, the possibility of reversibility becomes smaller and smaller, is represented by PoW.

Consensus mechanism is a large subject. We always hear about endless innovations, but it remains the same. As long as you understand the characteristics of distributed systems, consensus mechanism is not mysterious.

#共识机制 #热门话题