hachikuji commented on code in PR #12158: URL: https://github.com/apache/kafka/pull/12158#discussion_r873958800
########## core/src/main/scala/kafka/controller/KafkaController.scala: ########## @@ -468,14 +468,6 @@ class KafkaController(val config: KafkaConfig, // shutdown leader rebalance scheduler kafkaScheduler.shutdown() - offlinePartitionCount = 0 Review Comment: The way `updateMetrics` is written is a little annoying. While we're at it, would it be any clearer to revise `updateMetrics` to the following structure: ```scala if (isActive) { offlinePartitionCount = controllerContext.offlinePartitionCount ... } else { offlinePartitionCount = 0 ... } ``` -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: jira-unsubscr...@kafka.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org