The idea of Paxos was difficult to prove because the individual nodes propose certain values and the acceptors accept those values. However, there is no leader in the system, and individual nodes need to wait for a certain amount of time to see whether someone is proposing a value. If none of them proposes a value or timeout, then one of the nodes proposes a value, and the remaining nodes may accept or reject the proposal. If the node is getting a majority voting, then that node knows that its proposal is being accepted, and then it sends the accept message to all the nodes. If there are multiple proposers in the system, it becomes difficult to theoretically prove that the repeated execution of Paxos, which is called a multi-Paxos protocol, can achieve consensus in the closed distributed system.
When the Paxos designed, there was no leader concept because electing a leader requires a consensus algorithm. But, once the system has a leader, the entire system becomes streamline. The Raft algorithm improved the concept proposed in Paxos. It is like, rather than going for repeated Paxos or multi Paxos, it preferred leader election based on the majority voting.
In Raft, it first runs a Paxos type of algorithm to elect a leader. But, once a leader is elected, the elected leader can execute a series of transactions until either leader dies or fails. However, in Paxos, the multi-Paxos algorithm needs to run for consensus for executing each transaction.
The Raft consensus algorithm has improved the concept of leader election and made it easy to understand and easy to prove theoretically.
References
- NPTEL lecture series on Blockchains Architecture, Design and Use Cases by Prof. Sandip Chakraborty, IIT Kharagpur.
843 total views, 1 views today