Raft

Consensus is an algorithm in distributed systems that forces agents in the system to agree on consistent values and elect a leader.

Some well-known consensus algorithms are Paxos and Raft. Paxos and Raft deliver similar performances but Raft is less complex, easier to understand, and therefore becoming very popular in distributed store implementations.

As consensus algorithms, Consul and Etcd implement Raft while ZooKeeper implements Paxos. The CoreOS Etcd Go library, implementing Raft, is included into SwarmKit and Swarm Mode as a dependency (in vendor/), so in this book we'll focus more on it.

Raft is described in detail in the Ongaro, Ousterhout paper, and it is available at https://ramcloud.stanford.edu/raft.pdf. In the upcoming section ...

Get Native Docker Clustering with Swarm now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.