m1a2st commented on code in PR #16899:
URL: https://github.com/apache/kafka/pull/16899#discussion_r1763579857


##########
clients/src/main/java/org/apache/kafka/common/config/AbstractConfig.java:
##########
@@ -355,6 +355,14 @@ public Map<String, Object> 
valuesWithPrefixAllOrNothing(String prefix) {
         return nonInternalConfigs;
     }
 
+    protected void clearConfig(String key) {
+        Object value = values.get(key);
+        if (value instanceof Number)
+            values.put(key, 0);
+        else
+            values.remove(key);
+    }

Review Comment:
   The main reason is in `GroupRebalanceConfig`, the `session.timeout.ms` 
config in necessary that no matter consumer protocol is, so we should keep it 
in config map, can't remove it from key set. 
https://github.com/apache/kafka/blob/f1e7954ad1dd2dc865195cdb796e2b1d518f8b85/clients/src/main/java/org/apache/kafka/clients/GroupRebalanceConfig.java#L50



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