tinaselenge commented on code in PR #13459: URL: https://github.com/apache/kafka/pull/13459#discussion_r1172832601
########## tools/src/main/java/org/apache/kafka/tools/FeatureCommand.java: ########## @@ -307,25 +294,24 @@ private static void update(String op, Admin admin, Map<String, FeatureUpdate> up } }); - AtomicInteger numFailures = new AtomicInteger(); - errors.keySet().forEach(feature -> { - short level = updates.get(feature).maxVersionLevel(); - Optional<Throwable> maybeThrowable = errors.get(feature); + int numFailures = 0; + for (Map.Entry<String, Optional<Throwable>> entry : errors.entrySet()) { Review Comment: Spotbug is not happy when using keySet iterator and doing error.get(feature). And because we are not iterating on keyset, to traverse with sorted keys, we have to use TreeSet? -- 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