ijuma commented on code in PR #18727: URL: https://github.com/apache/kafka/pull/18727#discussion_r1937695933
########## clients/src/main/java/org/apache/kafka/common/protocol/ApiKeys.java: ########## @@ -264,8 +273,11 @@ public boolean hasValidVersion() { return oldestVersion() <= latestVersion(); } - public Optional<ApiVersionsResponseData.ApiVersion> toApiVersion(boolean enableUnstableLastVersion) { - short oldestVersion = oldestVersion(); + public Optional<ApiVersionsResponseData.ApiVersion> toApiVersion(boolean enableUnstableLastVersion, + Optional<ApiMessageType.ListenerType> listenerType) { Review Comment: It's a bit error prone to have 2 booleans. This approach has better type safety and it also fits with the calling code. -- 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