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 2022/07/04 14:56:17 UTC

[GitHub] [pulsar] hangc0276 commented on a diff in pull request #16336: [improve][java-client] Improve performance of multi-topic consumer with more than one IO thread

hangc0276 commented on code in PR #16336:
URL: https://github.com/apache/pulsar/pull/16336#discussion_r913080030


##########
pulsar-client/src/main/java/org/apache/pulsar/client/impl/MultiTopicsConsumerImpl.java:
##########
@@ -268,7 +275,7 @@ private void receiveMessageFromConsumer(ConsumerImpl<T> consumer) {
             } else {
                 // Call receiveAsync() if the incoming queue is not full. Because this block is run with
                 // thenAcceptAsync, there is no chance for recursion that would lead to stack overflow.
-                receiveMessageFromConsumer(consumer);
+                receiveMessageFromConsumer(consumer, messages.size() > 0);

Review Comment:
   If entered receiveMessageFromConsumer from this line and the messages.size() = 0 in this cycle, is there any chance to call batch receive in the future?



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