Start with what a user is allowed to observe#
Maya changes her username from maya1 to maya2. Must every user immediately see the new value? Must Maya see it? Can one session see maya2 and later move backward to maya1?
| Guarantee | Product behavior |
|---|---|
| Strong consistency | Reads follow a stated strong ordering/recency guarantee; define the exact model. |
| Eventual consistency | Copies may differ temporarily and are expected to converge if updates stop under stated assumptions. |
| Read-your-writes | A session observes its own completed updates. |
| Monotonic reads | A session does not move from a newer observed value to an older one. |
| Session consistency | A practical bundle of guarantees scoped to a client/session. |
Different operations deserve different guarantees#
- A bank balance or inventory reservation often needs stronger correctness.
- A social like count can often lag temporarily.
- A profile edit may need read-your-writes without global strong consistency.
- DNS demonstrates cached, gradual visibility, though its semantics are not a database consistency API.
Related practice problems
Use the manifest-backed prompts below to apply this lesson in a complete design.
- DynamoDB read consistencyAWS Documentation
Reach this point to mark the lesson as read.