AndrewJSchofield commented on code in PR #17418: URL: https://github.com/apache/kafka/pull/17418#discussion_r1797137085
########## clients/src/main/java/org/apache/kafka/clients/consumer/internals/events/ShareSubscriptionChangeEvent.java: ########## @@ -17,14 +17,31 @@ package org.apache.kafka.clients.consumer.internals.events; +import java.util.Collection; +import java.util.Collections; +import java.util.HashSet; +import java.util.Set; + /** * Application event indicating that the subscription state has changed, triggered when a user * calls the subscribe API. This will make the consumer join a share group if not part of it * yet, or just send the updated subscription to the broker if it's already a member of the group. */ -public class ShareSubscriptionChangeEvent extends ApplicationEvent { +public class ShareSubscriptionChangeEvent extends CompletableApplicationEvent<Void> { + + private final Set<String> topics; + + public ShareSubscriptionChangeEvent(final Collection<String> topics) { + super(Type.SHARE_SUBSCRIPTION_CHANGE, Long.MAX_VALUE); + this.topics = Collections.unmodifiableSet(new HashSet<>(topics)); Review Comment: Good point. I needed to rebase to use Java 11, but it works now. -- 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