codelipenghui commented on a change in pull request #9295:
URL: https://github.com/apache/pulsar/pull/9295#discussion_r564972796



##########
File path: 
pulsar-testclient/src/main/java/org/apache/pulsar/testclient/PerformanceConsumer.java
##########
@@ -338,6 +351,13 @@ public EncryptionKeyInfo getPrivateKey(String keyName, 
Map<String, String> keyMe
             consumerBuilder.cryptoKeyReader(keyReader);
         }
 
+        if (arguments.maxNumMessages > 0 || arguments.maxNumBytes > 0 || 
arguments.timeout > 0) {
+            consumerBuilder.batchReceivePolicy(BatchReceivePolicy.builder()
+                    .maxNumMessages(arguments.maxNumMessages)
+                    .maxNumBytes(arguments.maxNumBytes)
+                    .timeout(arguments.timeout, 
TimeUnit.MILLISECONDS).build());
+        }
+

Review comment:
       Only set the batchReceivePolicy does not able to measure the performance 
of batch-receive. Batch recieve is a separate method.




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

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to