chia7712 commented on PR #18997: URL: https://github.com/apache/kafka/pull/18997#issuecomment-2679890248
> that's the approach we took with FeaturesImage. Most callers use metadataVersionOrThrow. The rare use cases that may call it before it's set call the version that returns Optional and keep retrying until it's set (which is the desired behavior - it's not safe for them to proceed until then). I think it includes following changes. 1. remove `metadataVersion` from `FeatureControlManager` constructor, since the `TimelineObject<MetadataVersion>` will be changed to `TimelineObject<Optional<MetadataVersion>>`. And it is initialized with `Optional.empty` 2. `FeatureControlManager#metadataVersion` should be changed to `metadataVersionOrThrow`, similar to `FeaturesImage` 3. `CompleteActivationEvent` should NOT use `FeatureControlManager#metadataVersionOrThrow`if the log is empty, since the `FeatureControlManager` has not yet set the MV. If above list is correct, maybe we can address it in follow-up? -- 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]
