cmccabe commented on code in PR #19454:
URL: https://github.com/apache/kafka/pull/19454#discussion_r2045089584


##########
metadata/src/main/java/org/apache/kafka/controller/ClusterControlManager.java:
##########
@@ -309,8 +309,10 @@ public void activate() {
         long nowNs = time.nanoseconds();
         for (BrokerRegistration registration : brokerRegistrations.values()) {
             heartbeatManager.register(registration.id(), 
registration.fenced());
-            heartbeatManager.tracker().updateContactTime(
-                new BrokerIdAndEpoch(registration.id(), registration.epoch()), 
nowNs);
+            if (!registration.fenced()) {
+                heartbeatManager.tracker().updateContactTime(
+                    new BrokerIdAndEpoch(registration.id(), 
registration.epoch()), nowNs);

Review Comment:
   In general there can be a lot of session state. Maybe we'll persist it in 
the future, but I don't think something as minor as this would be the 
motivation.
   
   One thing we could do is have separate states for never unfenced (initial 
startup) and post-controlled-shutdown. That would let us have some better 
metrics. But it's not worth it for this PR.



-- 
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

Reply via email to