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


##########
core/src/test/java/kafka/test/junit/RaftClusterInvocationContext.java:
##########
@@ -247,52 +241,16 @@ public Map<Integer, ControllerServer> controllers() {
 
         public void format() throws Exception {
             if (formated.compareAndSet(false, true)) {
-                Map<String, Features> nameToSupportedFeature = new TreeMap<>();
-                Features.PRODUCTION_FEATURES.forEach(feature -> 
nameToSupportedFeature.put(feature.featureName(), feature));
-                Map<String, Short> newFeatureLevels = new TreeMap<>();
-
-                // Verify that all specified features are known to us.
-                for (Map.Entry<Features, Short> entry : 
clusterConfig.features().entrySet()) {
-                    String featureName = entry.getKey().featureName();
-                    short level = entry.getValue();
-                    if (!featureName.equals(MetadataVersion.FEATURE_NAME)) {
-                        if (!nameToSupportedFeature.containsKey(featureName)) {
-                            throw new FormatterException("Unsupported feature: 
" + featureName +
-                                ". Supported features are: " + String.join(", 
", nameToSupportedFeature.keySet()));
-                        }
-                    }
-                    newFeatureLevels.put(featureName, level);
-                }
-                newFeatureLevels.put(MetadataVersion.FEATURE_NAME, 
clusterConfig.metadataVersion().featureLevel());
-
-                // Add default values for features that were not specified.
-                Features.PRODUCTION_FEATURES.forEach(supportedFeature -> {

Review Comment:
   good point. I have a fix for this now... take a look.



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to