System Design
4. Database FundamentalsAnimated
Non-Relational Databases
Databases that do not use the fixed table model.
The idea
Document, key-value, wide-column and graph stores trade some relational features for flexible schemas or easy scaling.
Watch it work
Press play, pause, or step through. Some animations have settings you can change.
- client
- gateway / proxy
- service
- cache
- data store
- queue / stream
Independent machines coordinate only by passing messages.
- step:
- 1/4
- at:
- Node 1
1/8
The green dot is a request moving through the system.
Step by step
- 1Pick a model that fits the data shape
- 2Design around your access patterns
- 3Denormalise as needed
- 4Accept weaker joins and sometimes weaker consistency
Where it is used
Caches, sessions, catalogs, graphs.
Watch out for
Missing features such as joins can push complexity into your application.