f1amingo opened a new pull request, #11529:
URL: https://github.com/apache/rocketmq/pull/11529

   ### Which Issue(s) This PR Fixes
   
   - Fixes #11528
   
   ### Brief Description
   
   When a Lite pop response is lost, the lite topics it read stay leased to it 
and their events are already consumed, so the client's retry with the same 
attemptId cannot pick them up until the invisible time expires. This PR 
records, per client, the latest pop with an attemptId and the leases it takes. 
A retry of the same attemptId releases these leases without committing offset 
and re-dispatches them, so they are redelivered from the same offset in order. 
A pop superseded by a newer request of the client stops reading and passes on 
its events, and a lease it takes afterwards is released under the queue lock. 
Receipt handles of a released lease can no longer renew, suspend or commit 
offset. This assumes at most one pop with an attemptId in flight per client on 
a broker.
   
   ### How Did You Test This Change?
   
   Added PopLiteAttemptRecoveryTest and 
PopLiteMessageProcessorAttemptReleaseTest covering lost responses, overlapping 
pops and queue lock contention. Existing Lite, ChangeInvisibleTime and 
ConsumerOrderInfo tests pass.
   


-- 
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: [email protected]

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

Reply via email to