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/13 10:07:43 UTC

[GitHub] [pulsar] HQebupt opened a new issue, #18036: [Bug] consumer backlog eviction policy should not reset read position of the consumer

HQebupt opened a new issue, #18036:
URL: https://github.com/apache/pulsar/issues/18036

   ### Search before asking
   
   - [X] I searched in the [issues](https://github.com/apache/pulsar/issues) and found nothing similar.
   
   
   ### Version
   
   Pulsar: latest
   JDK: 17
   
   ### Minimal reproduce step
   
   - Run unit test: org.apache.pulsar.broker.service.BacklogQuotaManagerTest#testConsumerBacklogEvictionTimeQuota
   
   ### What did you expect to see?
   
   1. The backlog eviction policy should not the reset read position of the consumer. It is due to wrong method for resetting mark delete position.
   2. Reduce the resetting mark delete position request.
   
   ### What did you see instead?
   
   - 1. When I run the unit test, I found the cursor c1 's read position was reset by `BacklogQuotaManager`. The backlog eviction policy should not the reset read position of the consumer. See the following log.
   ```
   2022-10-13T17:50:37,488 - INFO  - [pulsar-backlog-quota-checker-64-1:BacklogQuotaManager@89] - Backlog quota type message_age exceeded for topic [persistent://prop/ns-quota/topic3c8347406-bbe5-40e9-9f08-eced5d838a42]. Applying [consumer_backlog_eviction] policy
   2022-10-13T17:50:37,492 - INFO  - [BookKeeperClientWorker-OrderedExecutor-1-0:ManagedCursorImpl@1193] - [prop/ns-quota/persistent/topic3c8347406-bbe5-40e9-9f08-eced5d838a42] Initiate reset position to 1:0 on cursor c1
   
   2022-10-13T17:50:37,628 - INFO  - [bookkeeper-ml-scheduler-OrderedScheduler-1-0:ManagedCursorImpl$30@2963] - [prop/ns-quota/persistent/topic3c8347406-bbe5-40e9-9f08-eced5d838a42] Updated cursor c1 with ledger id 3 md-position=0:-1 rd-position=2:4
   2022-10-13T17:50:37,795 - INFO  - [BookKeeperClientWorker-OrderedExecutor-1-0:ManagedCursorImpl@1193] - [prop/ns-quota/persistent/topic3c8347406-bbe5-40e9-9f08-eced5d838a42] Initiate reset position to 2:0 on cursor c1
   2022-10-13T17:50:37,799 - INFO  - [BookKeeperClientWorker-OrderedExecutor-1-0:ManagedCursorImpl$9@1245] - [prop/ns-quota/persistent/topic3c8347406-bbe5-40e9-9f08-eced5d838a42] reset position to 2:0 skipping from current read position 1:0 on cursor c1
   
   ```
   - 2. There are a lot of redundant reset mark delete position requests in the log.
   <img width="1840" alt="image" src="https://user-images.githubusercontent.com/4970972/195565655-98f2940e-97cc-40a4-b4bc-dc10f6edddd3.png">
   
   
   ### Anything else?
   
   _No response_
   
   ### Are you willing to submit a PR?
   
   - [X] I'm willing to submit a PR!


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

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


[GitHub] [pulsar] HQebupt closed issue #18036: [Bug] consumer backlog eviction policy should not reset read position of the consumer

Posted by GitBox <gi...@apache.org>.
HQebupt closed issue #18036: [Bug] consumer backlog eviction policy should not reset read position of the consumer
URL: https://github.com/apache/pulsar/issues/18036


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