Course contentsShow
← System Design
Lesson 553 of 1,91915. Consistency ModelsFree lesson

Choosing Consistency Levels

Tradeoffs between consistency models, performance, availability, and application requirements.

Choosing Consistency Levels

What you'll learn: How to select the right consistency model by balancing performance, availability, and your application's correctness needs.

Understanding the Tradeoff Space

Now that you've seen the spectrum of consistency models—from strong consistency (linearizability) to eventual consistency and everything in between (causal, session, monotonic reads, etc.)—how do you actually choose?

The decision hinges on three competing forces:

  1. Consistency requirements - How correct must your data appear?
  2. Performance/Latency - How fast must operations complete?
  3. Availability - Can you tolerate downtime during failures?

Think of it like ordering food: You can have it fast, cheap, or perfect—but rarely all three. Strong consistency is like a custom-made meal: correct but slow. Eventual consistency is like fast food: quick and always available, but maybe not exactly what you expected right away.

Making the Choice

Start with application requirements:

  • Financial transactions? → Strong consistency or strict serializability (correctness is non-negotiable)
  • Social media feed? → Eventual consistency (stale likes won't break anything)
  • Shopping cart? → Session consistency (user's own actions must be visible)
  • Collaborative editing? → Causal consistency (preserve cause-effect relationships)

Consider your architecture:

  • Multi-region deployments often can't sustain strong consistency without severe latency penalties
  • Single-leader systems naturally support stronger guarantees
  • High-traffic read paths benefit from weaker models that allow caching

Hybrid approaches work: Many systems use strong consistency for critical writes (payment processing) while accepting eventual consistency for reads (product reviews).

Key Takeaway: Choosing a consistency level isn't about picking the "best" model—it's about matching guarantees to business requirements while accepting the performance and availability trade-offs that come with your choice.