[ https://issues.apache.org/jira/browse/KAFKA-499?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13457964#comment-13457964 ]
Neha Narkhede commented on KAFKA-499: ------------------------------------- ReplicaStateMachine: The purpose of isShuttingDown is to avoid triggering state changes from the BrokerChangeListener when the state machine is in the middle of a shutdown. Ditto for PartitionStateMachine. PartitionStateMachine: The allLeaders cache stores the controller's leader decision for all existing partitions in zookeeper. A partition is deleted from this list only when it is deleted. Rest of the comments are addressed. > Refactor controller state machine > ---------------------------------- > > Key: KAFKA-499 > URL: https://issues.apache.org/jira/browse/KAFKA-499 > Project: Kafka > Issue Type: Bug > Affects Versions: 0.8 > Reporter: Neha Narkhede > Assignee: Neha Narkhede > Priority: Blocker > Labels: optimization > Attachments: kafka-499-v1.patch, kafka-499-v2.patch, > kafka-499-v3.patch, kafka-499-v4.patch > > Original Estimate: 96h > Remaining Estimate: 96h > > Currently, the controller logic is very procedural and is similar to > KafkaZookeeper. Controller should have a well defined state machine with > states and transitions. This will make it easier to understand and maintain > the controller code. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira