The Consistency Spectrum
What you'll learn: You'll understand that consistency in distributed systems isn't binary—it's a spectrum with many intermediate guarantees between strong and eventual consistency.
Not Just Two Options
When we learned about strong consistency and eventual consistency, it might have seemed like an either-or choice. In reality, distributed systems offer a wide range of consistency models that sit between these extremes. Think of it like a volume knob rather than an on/off switch.
The Full Range
At one end, linearizability (strong consistency) guarantees that operations appear instantaneous and in global order—the strongest possible guarantee. At the other end, eventual consistency promises only that replicas will converge "eventually," with few real-time guarantees.
In between, you have models like:
- Sequential consistency (operations appear in some total order, but not necessarily real-time)
- Causal consistency (maintains cause-and-effect relationships)
- Read-your-writes (you always see your own updates)
- Monotonic reads (you never go backward in time)
- Session consistency (strong consistency within a user session, weaker globally)
Why the Spectrum Matters
Different consistency levels have different costs in terms of latency, availability, and performance. Stronger guarantees require more coordination between nodes, which means higher latency. Weaker guarantees allow systems to respond faster and stay available during partitions.
You choose where on the spectrum to operate based on your application's needs. Banking transactions need strong consistency. Social media likes can tolerate eventual consistency. User profile updates might need read-your-writes consistency.
Key Takeaway: Consistency guarantees exist on a spectrum—choosing the right level for each operation lets you balance correctness, performance, and availability based on specific business requirements.