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/10/19 08:57:13 UTC

[GitHub] [pulsar] RobertIndie commented on a diff in pull request #18107: [improve][client] Support MAX_ACK_GROUP_SIZE configurable

RobertIndie commented on code in PR #18107:
URL: https://github.com/apache/pulsar/pull/18107#discussion_r999148588


##########
pulsar-client/src/main/java/org/apache/pulsar/client/impl/PersistentAcknowledgmentsGroupingTracker.java:
##########
@@ -60,7 +60,7 @@ public class PersistentAcknowledgmentsGroupingTracker implements Acknowledgments
     /**
      * When reaching the max group size, an ack command is sent out immediately.
      */
-    private static final int MAX_ACK_GROUP_SIZE = 1000;
+    private int MAX_ACK_GROUP_SIZE;

Review Comment:
   ```suggestion
       private final int maxAckGroupSize;
   ```



##########
pulsar-client/src/main/java/org/apache/pulsar/client/impl/ConsumerBuilderImpl.java:
##########
@@ -327,6 +327,14 @@ public ConsumerBuilder<T> acknowledgmentGroupTime(long delay, TimeUnit unit) {
         return this;
     }
 
+    @Override
+    public ConsumerBuilder<T> acknowledgmentGroupSize(int messageNum) {
+        checkArgument(messageNum >= 0, "acknowledgementsGroupSize needs to be >= 0");

Review Comment:
   Maybe we need to make it greater than 0?



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