kevin-wu24 commented on code in PR #20551:
URL: https://github.com/apache/kafka/pull/20551#discussion_r2369434956


##########
metadata/src/main/java/org/apache/kafka/metadata/storage/Formatter.java:
##########
@@ -348,20 +352,20 @@ private short effectiveKRaftFeatureLevel(Optional<Short> 
configuredKRaftVersionL
             if (configuredKRaftVersionLevel.get() == 0) {
                 if (hasDynamicQuorum()) {
                     throw new FormatterException(
-                        "Cannot set kraft.version to " +
-                        configuredKRaftVersionLevel.get() +
-                        " if one of the flags --standalone, 
--initial-controllers, or --no-initial-controllers is used. " +
+                        "Cannot set kraft.version to " + 
configuredKRaftVersionLevel.get() +
+                        " if controller.quorum.voters is empty and one of the 
flags --standalone, " +
+                        "--initial-controllers, or --no-initial-controllers is 
used. " +

Review Comment:
   Sorry for the confusion, but the original error message should be correct. 
If the static voters is not specified, --no-intial-controllers is set, and 
kraft.version is set to 0, the formatter should fail. The message says if 
controller.quorum.voters is empty AND one of the KIP-853 flags is set.
   
   If static voters is specified, --no-initial-controllers i set, and 
kraft.version is set to 0, the tool does not fail. The `hasDynamicQuorum` 
boolean is true when static voters is empty and false otherwise.



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