System Design
5. Advanced Database ArchitectureAnimated
Multi-Master Replication
Several nodes accept writes.
The idea
Each master replicates changes to the others. This improves write availability and locality but needs conflict resolution.
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
Both nodes serve traffic at all times.
- step:
- 1/4
- at:
- Clients
1/11
The green dot is a request moving through the system.
Step by step
- 1Clients write to any master
- 2Each master forwards the change
- 3Others apply it
- 4Conflicts are resolved by a rule
Where it is used
Multi-region writes.
Watch out for
Conflicts: last-write-wins can silently lose data.