What is Eventual Consistency

Eventual consistency is a consistency model that guarantees all replicas will converge to the same value, given that no new updates are made to the data. It does not specify when convergence happens -- it could be milliseconds or minutes. During the convergence window, different replicas may return different values for the same key. This is the weakest useful consistency guarantee, and it is the default model for most highly available distributed systems.

How it works

In an eventually consistent system, a write is acknowledged as soon as one replica (or a small subset) accepts it. The update then propagates asynchronously to other replicas through replication. During propagation, a client reading from a replica that has not yet received the update sees stale data.

Conflict resolution determines what happens when two replicas receive conflicting writes to the same key. Common strategies include:

  • Last-writer-wins (LWW) -- the write with the highest timestamp wins. Simple, but can silently discard writes. DynamoDB and Cassandra use this by default.
  • Vector clocks -- track causal ordering across nodes. Conflicting writes are detected and surfaced to the application for resolution. Amazon's original Dynamo paper used this approach.
  • CRDTs (Conflict-free Replicated Data Types) -- data structures designed so that concurrent updates always converge without conflicts. Counters, sets, and registers can be designed as CRDTs.

The CAP theorem explains why eventual consistency exists. During a network partition, a system can either refuse writes (choosing consistency) or accept them on available nodes and reconcile later (choosing availability). Eventually consistent systems choose availability.

The acronym BASE -- Basically Available, Soft state, Eventually consistent -- is sometimes used as the counterpart to ACID for describing these systems.

Why it matters

Eventual consistency is not a design flaw -- it is a deliberate choice that enables low-latency writes across geographically distributed systems. DNS, CDNs, and global databases like DynamoDB are all eventually consistent. Understanding this model helps you design applications that tolerate stale reads, use idempotent operations, and avoid anomalies.

See How Consistency Works for the full spectrum from linearizability to eventual consistency.