-
Separates the algorithm in distinct problems
- Leader election
- Log Replication
- safety
- configuration updates. Cluster to continue operating during config changes.
-
Only the leader can mutate the state. Clients communicate only with leader. There is always only 1 leader. The leader has highest Generation number (GN) (Term)
-
3 states
- Leader, follower, Candidate
-
heartbeats and election timeout
-
RPC’s are idempotent
-
Compaction
-
Ensures safety
- network delays, partitions, packet loss, duplication and reordering
-
Techniques designing the algorithm
- Problem decomposition
- State space reduction.
- e.g. only 1 leader, all mutates through this 1 leader. Leader log is always most up to date, logs are not allowed to have holes.