redlsz opened a new issue, #10949: URL: https://github.com/apache/rocketmq/issues/10949
### Before Creating the Enhancement Request - [x] I have confirmed that this should be classified as an enhancement rather than a bug/feature. ### Summary With popConsumerKVServiceEnable = true, a queue's consumer offset is only advanced by pop requests, and the committed value always lags one round behind the real position. There is no broker-side task that closes this gap, so once a consumer drains the backlog, acks everything and goes offline, the offset stays behind indefinitely and reported lag never reaches zero. Adding background convergence would make the offset reflect the actual consumption position regardless of client polling behavior. ### Motivation Ack no longer advances the offset (PopConsumerService#ackAsync only deletes the record), and the commit now rides on pop using the start offset of the current batch, while the real watermark nextBeginOffset goes only to pullOffsetTable. No background task closes the gap: run() only revives, and PopConsumerCache#cleanupRecords skips the commit once the queue drains because getMinOffsetInBuffer() returns -1 — with enablePopBufferMerge=false there is no periodic committer at all. The legacy PopBufferMergeService path does not need one, since ack itself commits nextBeginOffset. ### Describe the Solution You'd Like Add a periodic broker-side task in PopConsumerService that converges offsetTable toward pullOffsetTable, bounded by the minimum in-flight offset still held in the cache, so it works for both enablePopBufferMerge values without depending on any further client request. ### Describe Alternatives You've Considered / ### Additional Context _No response_ -- 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]
