3.2. Replication Strategies
Replication keeps copies of data on multiple nodes — the only way to survive a machine loss and the only way to scale reads beyond one server. But the instant you have more than one copy, you inherit the problem of keeping them agreed, and the network guarantees you will not always succeed. This chapter covers the three replication topologies (single-leader, multi-leader, leaderless), the split-brain risk that failover creates, replication lag and the anomalies it produces, and the anti-entropy mechanisms that let divergent replicas heal.
Topics Covered
Section titled “Topics Covered”- 3.2.1. Leader-Based Replication: Synchronous vs. Asynchronous: Covers single-leader replication and the synchronous-versus-asynchronous choice between durability and latency.
- 3.2.2. Failover and Leader Election: The Split-Brain Risk: Explains automatic failover and the split-brain risk when two nodes both believe they are leader.
- 3.2.3. Replication Lag Problems: Read-Your-Own-Writes: Analyzes the anomalies replication lag produces and the read-your-own-writes guarantee that fixes the worst of them.
- 3.2.4. Multi-Leader Replication: Write Conflicts and Resolution: Covers multi-leader topologies, the write conflicts they inevitably create, and conflict-resolution strategies.
- 3.2.5. Leaderless Replication (Dynamo-style): Quorum R + W > N: Explains Dynamo-style quorums where R + W > N provides tunable consistency without a leader.
- 3.2.6. Anti-Entropy: Read Repair and Merkle Trees: Covers read repair and Merkle trees, the anti-entropy mechanisms that let divergent replicas reconverge.