How does kafka handle network partitions? : <p>Kafka has the concept of a in-sync replica set, which is the set of nodes that aren't too far behind the leader. </p>

<p>What happens if the network cleanly partitions so that a minority containing the leader is on one side, and a majority containing the other in-sync nodes on the other side? </p>

<p>The minority/leader-side presumably thinks that it lost a bunch of nodes, reduces the ISR size accordingly, and happily carries on. </p>

<p>The other side probably thinks that it lost the leader, so it elects a new one and happily carries on. </p>

<p>Now we have two leaders in the same cluster, accepting writes independently. In a system that requires a majority of nodes to proceed after a partition, the old leader would step down and stop accepting writes. </p>

<p>What happens in this situation in Kafka? Does it require majority vote to change the ISR set? If so, is there a brief data loss until the leader side detects the outages?</p>
