chia7712 commented on a change in pull request #8826: URL: https://github.com/apache/kafka/pull/8826#discussion_r520237060
########## File path: clients/src/main/java/org/apache/kafka/common/network/ChannelBuilders.java ########## @@ -159,24 +159,25 @@ private static ChannelBuilder create(SecurityProtocol securityProtocol, } // Visibility for testing - protected static Map<String, Object> channelBuilderConfigs(final AbstractConfig config, final ListenerName listenerName) { - Map<String, ?> parsedConfigs; + @SuppressWarnings("unchecked") + static Map<String, Object> channelBuilderConfigs(final AbstractConfig config, final ListenerName listenerName) { + Map<String, Object> parsedConfigs; if (listenerName == null) - parsedConfigs = config.values(); + parsedConfigs = (Map<String, Object>) config.values(); Review comment: ```java if (listenerName == null) parsedConfigs = (Map<String, Object>) config.values(); else parsedConfigs = config.valuesWithPrefixOverride(listenerName.configPrefix()); ``` the method ```config.valuesWithPrefixOverride``` also returns ```RecordingMap so it is ok. ---------------------------------------------------------------- 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. For queries about this service, please contact Infrastructure at: us...@infra.apache.org