N, R, W Configuration Trade-offs
What you'll learn: How adjusting the replica count (N), read quorum (R), and write quorum (W) values changes your system's behavior across consistency, availability, and latency dimensions.
The Configuration Triangle
Remember from the quorum condition that R + W > N ensures strong consistency. But within that constraint, you have many valid combinations—and each one makes different trade-offs.
Think of it like adjusting three sliders on a control panel: moving one affects the others, and you're optimizing for different goals based on your application's needs.
Common Configurations
High consistency, slower writes: N=3, R=1, W=3
- Every write must reach all replicas (slow, blocks on multiple nodes)
- Reads only need one replica (fast!)
- Use when: reads dominate, and you want fast reads with strong write consistency
Balanced approach: N=3, R=2, W=2
- Both reads and writes require majority agreement
- Moderate latency on both operations
- Use when: roughly equal read/write traffic with strong consistency needs
High availability, eventual consistency: N=3, R=1, W=1
- Reads and writes only need one replica (very fast!)
- No longer satisfies
R + W > N, so you get eventual consistency - Use when: speed and availability matter more than immediate consistency (like social media feeds)
Write-heavy optimization: N=5, R=3, W=2
- Writes are faster (only need 2 nodes)
- Reads slower (need 3 nodes)
- Still strongly consistent since 3 + 2 > 5
- Use when: write performance is critical but you need consistency
The Trade-off Reality
Higher N increases durability but makes writes slower. Higher W improves consistency but reduces write availability. Higher R slows reads. There's no free lunch—you're always choosing which dimension matters most for your use case.
Key Takeaway: N, R, and W configurations let you fine-tune the balance between consistency strength, operation latency, and fault tolerance—choosing the right values depends on whether your workload prioritizes read speed, write speed, or strict consistency guarantees.