Unclean leader election: Kafka trolley problem where you always end up pulling the lever
TL;DR Apache Kafka maintains a set of in-sync replicas (ISR) for each topic partition. During normal operations there is at least one broker in the set, the leader. Typically, in order to tolerate losing a single broker, there are more than one, and one of those is the leader. In such a setup, when the leader is lost, another broker becomes the leader. However, if the last broker in the ISR is lost, the partition goes offline. Once a partition is offline, producers and consumers fail to use it.