2 个节点宕机后,kafka 没有选举新的领导者

kafka is not electiong new leader after 2 nodes are down

我们在 3 个 kafka 节点的环境中测试 scalein 每个人都有经纪人和动物园管理员服务 replica.factor=2 服务在 2 个节点上宕机后 分区的领导者保持旧的并且没有移动到唯一的节点

并发送一条错误消息

错误:分区 0 没有领导者。跳过获取偏移量 错误:分区 2 没有领导者。跳过获取偏移量 错误:分区 3 没有领导者。跳过获取偏移量

为什么会这样?

here you can see how the leaders stayed even though there is replica set

根据kafka configuration

The replication factor for the offsets topic (set higher to ensure availability). Internal topic creation will fail until the cluster size meets this replication factor requirement.

我猜想 kafka 集群无法为副本因子大于其集群大小的主题提供服务或做任何事情