jsancio commented on code in PR #21122:
URL: https://github.com/apache/kafka/pull/21122#discussion_r2920400212
##########
server-common/src/main/java/org/apache/kafka/server/common/FinalizedFeatures.java:
##########
@@ -20,27 +20,125 @@
import java.util.Map;
import java.util.Objects;
-public record FinalizedFeatures(
- MetadataVersion metadataVersion,
- Map<String, Short> finalizedFeatures,
- long finalizedFeaturesEpoch
-) {
- public static FinalizedFeatures fromKRaftVersion(MetadataVersion version) {
- return new FinalizedFeatures(version, Map.of(), -1);
- }
+/**
+ * Represents the finalized feature levels for a Kafka cluster.
+ * <p>
+ * This class can be in one of three states:
+ * <ul>
+ * <li>Unknown - metadata version is not yet known (use {@link
#unknown()})</li>
+ * <li>KRaft version only - only metadata version is known (use {@link
#fromKRaftVersion(MetadataVersion)})</li>
Review Comment:
KRaft version only? Do you mean metadata version only?
I would suggest adding context for when is unknown used vs metadata only
used vs "full features" is used.
--
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]