Databases & Data Storage
Eventual Consistency
Definition
Eventual consistency is a consistency model used in distributed computing that guarantees that, if no new updates are made to a given data item, all accesses to that item will eventually return the last updated value.
Why It Matters
It is a weaker consistency model than strong consistency, but it allows for higher availability and better performance in distributed systems. It is a core tenet of the BASE model.
Contextual Example
When you update your profile picture on a social media site, it might take a few seconds or minutes for all your friends to see the new picture. During this time, the system is in an inconsistent state, but it will eventually become consistent.
Common Misunderstandings
- Eventual consistency does not mean the system is unreliable; it just means there is a measurable delay before all replicas are in sync.
- This model is common in highly available NoSQL databases like Cassandra and DynamoDB.