[ https://issues.apache.org/jira/browse/KAFKA-1120?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15689028#comment-15689028 ]
James Cheng commented on KAFKA-1120: ------------------------------------ No, because broker 1 was up and running by 22:58:01,688. Broker 1 just sat there and did nothing, because the controller didn't send it any messages to follow anyone. It was not leader for any partitions, and did not attempt to follow anyone. Here is the relevant timeline on broker 1: {noformat} [2016-11-22 22:55:18,814] INFO [Kafka Server 1], Starting controlled shutdown (kafka.server.KafkaServer) [2016-11-22 22:57:11,437] INFO [Kafka Server 1], shut down completed (kafka.server.KafkaServer) [2016-11-22 22:57:40,168] INFO starting (kafka.server.KafkaServer) [2016-11-22 22:57:43,130] INFO Creating /brokers/ids/1 (is it secure? false) (kafka.utils.ZKCheckedEphemeral) [2016-11-22 22:57:43,134] INFO Registered broker 1 at path /brokers/ids/1 with addresses: PLAINTEXT -> EndPoint(core01.tec2.tivo.com,9092,PLAINTEXT) (kafka.utils.ZkUtils) {noformat} > Controller could miss a broker state change > -------------------------------------------- > > Key: KAFKA-1120 > URL: https://issues.apache.org/jira/browse/KAFKA-1120 > Project: Kafka > Issue Type: Bug > Components: core > Affects Versions: 0.8.1 > Reporter: Jun Rao > > When the controller is in the middle of processing a task (e.g., preferred > leader election, broker change), it holds a controller lock. During this > time, a broker could have de-registered and re-registered itself in ZK. After > the controller finishes processing the current task, it will start processing > the logic in the broker change listener. However, it will see no broker > change and therefore won't do anything to the restarted broker. This broker > will be in a weird state since the controller doesn't inform it to become the > leader of any partition. Yet, the cached metadata in other brokers could > still list that broker as the leader for some partitions. Client requests > routed to that broker will then get a TopicOrPartitionNotExistException. This > broker will continue to be in this bad state until it's restarted again. -- This message was sent by Atlassian JIRA (v6.3.4#6332)