Table of Contents

About

A leader handles all read and write requests for a partition while the followers passively replicate the leader.

Each server acts as a leader for some of its partitions and a follower for others so load is well balanced within the cluster.

Election

When the leader shuts down or fails, the next leader is chosen from among the followers (in-sync replicas).

In case some Kafka node goes down or rebalance is triggered due to addition of new nodes, Zookeeper runs the leader election algorithm.