You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@rocketmq.apache.org by "f1amingo (via GitHub)" <gi...@apache.org> on 2026/09/28 08:54:50 UTC

[I] [Bug] Fix Lite topic ack re-dispatching the event while holding the pop lock [rocketmq]

f1amingo opened a new issue, #11250:
URL: https://github.com/apache/rocketmq/issues/11250

   ### Before Creating the Bug Report
   
   - [x] I found a bug, not just asking a question.
   - [x] I have searched the GitHub Issues and Discussions and believe this is not a duplicate.
   - [x] I have confirmed this bug belongs to the current repository.
   
   ### Runtime platform environment
   
   OS: macOS / Linux
   
   ### RocketMQ version
   
   branch: develop
   
   ### JDK Version
   
   Oracle JDK 8
   
   ### Describe the Bug
   
   When a lite message is acked, the broker re-dispatches the lite topic to the consumer while still holding the pop lock of that lite topic. A pop that takes this event during that window cannot acquire the lock, so it skips the lite topic, and the event is already consumed and not re-queued. If no other notification comes for that lite topic, its remaining messages are not delivered.
   
   ### Steps to Reproduce
   
   1. A consumer pops a lite topic with several messages in FIFO order.
   2. The consumer acks the first message; the ack commits the offset and re-dispatches the lite topic while holding the pop lock.
   3. A pop running concurrently takes the re-dispatched event before the ack releases the lock, fails to acquire the lock and skips the lite topic.
   
   ### What Did You Expect to See?
   
   A pop triggered by the ack's re-dispatch can read the lite topic, and the remaining messages are delivered.
   
   ### What Did You See Instead?
   
   The re-dispatch happens while the lock is still held, so the triggered pop may fail to acquire the lock and the event is dropped.
   
   ### Additional Context
   
   Found by code review while investigating #11248. The dispatch decision needs the lock, but the dispatch itself does not.
   


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

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


Re: [I] [Bug] Fix Lite topic ack re-dispatching the event while holding the pop lock [rocketmq]

Posted by "RongtongJin (via GitHub)" <gi...@apache.org>.
RongtongJin closed issue #11250: [Bug] Fix Lite topic ack re-dispatching the event while holding the pop lock
URL: https://github.com/apache/rocketmq/issues/11250


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

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