You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by GitBox <gi...@apache.org> on 2021/09/24 09:16:20 UTC

[GitHub] [pulsar] metahys commented on a change in pull request #12118: [Issue 1240][C++] Support setting ConsumerEventListener in pulsar cpp client

metahys commented on a change in pull request #12118:
URL: https://github.com/apache/pulsar/pull/12118#discussion_r715452313



##########
File path: pulsar-client-cpp/tests/ConsumerConfigurationTest.cc
##########
@@ -28,11 +28,19 @@ DECLARE_LOG_OBJECT()
 
 using namespace pulsar;
 
+class DummyEventListener : public ConsumerEventListener {
+   public:
+    virtual void becomeActive(Consumer consumer, int partitionId) override {}

Review comment:
       I have added unit tests in `ConsumerTest`. And I renamed "become" to "became" to make it consistent with java client. The call to `registerConsumer` is moved from `handleCreateConsumer` to `connectionOpened`, so that we can handle commands such as `ACTIVE_CONSUMER_CHANGE` properly.
   
   @merlimat Please take a look.
   
   




-- 
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: commits-unsubscribe@pulsar.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org