rocketmq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jinrongt...@apache.org
Subject [rocketmq] 15/22: fix(litePullConsumer):delete invalid method to get next pullBatchSize (#1702)
Date Mon, 20 Jan 2020 13:25:48 GMT
This is an automated email from the ASF dual-hosted git repository.

jinrongtong pushed a commit to branch test-release
in repository https://gitbox.apache.org/repos/asf/rocketmq.git

commit b3e8969a11f2efeb403a363bef4832290408553a
Author: rongtong <jinrongtong5@163.com>
AuthorDate: Tue Jan 7 20:05:49 2020 +0800

    fix(litePullConsumer):delete invalid method to get next pullBatchSize (#1702)
---
 .../rocketmq/client/impl/consumer/DefaultLitePullConsumerImpl.java | 7 ++-----
 1 file changed, 2 insertions(+), 5 deletions(-)

diff --git a/client/src/main/java/org/apache/rocketmq/client/impl/consumer/DefaultLitePullConsumerImpl.java
b/client/src/main/java/org/apache/rocketmq/client/impl/consumer/DefaultLitePullConsumerImpl.java
index cd4d4cf..c3eb7fb 100644
--- a/client/src/main/java/org/apache/rocketmq/client/impl/consumer/DefaultLitePullConsumerImpl.java
+++ b/client/src/main/java/org/apache/rocketmq/client/impl/consumer/DefaultLitePullConsumerImpl.java
@@ -211,10 +211,6 @@ public class DefaultLitePullConsumerImpl implements MQConsumerInner {
         }
     }
 
-    private int nextPullBatchSize() {
-        return Math.min(this.defaultLitePullConsumer.getPullBatchSize(), consumeRequestCache.remainingCapacity());
-    }
-
     public synchronized void shutdown() {
         switch (this.serviceState) {
             case CREATE_JUST:
@@ -775,7 +771,8 @@ public class DefaultLitePullConsumerImpl implements MQConsumerInner {
                         subscriptionData = FilterAPI.buildSubscriptionData(defaultLitePullConsumer.getConsumerGroup(),
                             topic, SubscriptionData.SUB_ALL);
                     }
-                    PullResult pullResult = pull(messageQueue, subscriptionData, offset,
nextPullBatchSize());
+                    
+                    PullResult pullResult = pull(messageQueue, subscriptionData, offset,
defaultLitePullConsumer.getPullBatchSize());
 
                     switch (pullResult.getPullStatus()) {
                         case FOUND:


Mime
View raw message