The encyclopedia · Engineering & Operations · Technical decision · 2013–2014
Raft matched Paxos but was designed to be understood, so it won
Raft matched Paxos on safety and performance but deliberately made itself understandable, and so got more consensus systems built correctly.
Stanford University
the move
Paxos was the accepted consensus algorithm, but it was hard to understand and hard to implement, so production systems built on it were prone to subtle bugs that only surfaced under leader failure.
Raft was written with a different priority: it is equivalent to Paxos in fault-tolerance and performance, and the difference is that it is designed to be easy to understand. Its authors broke consensus into a leader election, a log replicated in order, and a safety rule.
That separation is what let a wider audience implement it correctly. Understandability was treated as a first-class requirement, and the result was a consensus algorithm teams could actually reason about and ship.
why it works
- Understandable phases map to what a programmer can verify.
- Cleverness in consensus tends to breed implementation bugs.
- Wider correct adoption beats a marginal performance edge.
what transfers
When correctness depends on many others getting it right, make the hard thing easy to verify; a design that is merely clever costs more through bugs than it gains in elegance.
what came after
Raft was adopted by etcd, Consul, CockroachDB and many other distributed systems, and became the default way engineers learn and build consensus.
references
spotted an error? The archive wants to know.