40436michael opened a new pull request, #24291:
URL: https://github.com/apache/kafka/pull/24291

   In 4.4, calling `subscribe(topics)` after `subscribe(topics, listener)`
   removed the listener. Since #22271, trunk keeps it, because the
   consumers only update the rebalance listener when one is passed.
   KIP-1306 states that there is no change in behavior with the existing
   `subscribe()` methods with the callback argument.
   
   Track which API registered the listener in `ConsumerSubscriptionState`.
   `subscribe()` without a listener now removes a listener registered via
   the deprecated `subscribe(..., listener)` methods, but keeps one set via
   `setRebalanceListener()`.
   
   Also apply the same fix to the `Pattern` and `SubscriptionPattern`
   variants and to `MockConsumer`, update the `KafkaConsumer` Javadoc, and
   add unit tests, a `MockConsumer` test, and integration tests for both
   group protocols.
   
   Co-Authored-By: Claude Opus 5.5 <[email protected]>
   


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