Single Leader Replication
This form of replication is also known as the active/passive or master-slave replication. Consider a group of nodes that host a replica of a database. Out of all the nodes, one of the nodes acts as the leader of the group and the rest are designated as the followers.
- The leader accepts all the writes from the other participants/clients in the system and writes the change to its local storage. The change is then propagated to the followers. The changes made at the leader must be sent in the same order to the followers. These changes sent from the leader to its followers is also known as the *change stream* or replication log
- Clients in the system can make a read request either to the leader or any one of the followers. In an ideal situation, all the follower nodes will have caught up to the leader and present the same snapshot of data to the clients as that exists on the leader.
- Client initiates a write request with the leader
Get hands-on with 1400+ tech skills courses.