dragonls commented on PR #17573:
URL: https://github.com/apache/pulsar/pull/17573#issuecomment-1248158692

   > > If there are brokers shutdown with OOM or other situation, which make 
the broker not shutdown gracefully, the new broker load the topics and then do 
subscription expiry check soon before consumer reconnected, then the 
subscription may be deleted unexpectedly.
   > 
   > If the topic is loaded by another broker, the `lastActive` will be reset 
to `clock.millis()`
   > 
   > 
https://github.com/apache/pulsar/blob/a6fe5bb2f88c946e1bc27a45fad1751aa76bd971/managed-ledger/src/main/java/org/apache/bookkeeper/mledger/impl/ManagedCursorImpl.java#L305
   > 
   > How the above situation can happen?
   
   `lastActive` is set to `clock.millis()` while initilized, but will be 
covered by `recover()` soon.
   
https://github.com/apache/pulsar/blob/a6fe5bb2f88c946e1bc27a45fad1751aa76bd971/managed-ledger/src/main/java/org/apache/bookkeeper/mledger/impl/ManagedCursorImpl.java#L414


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