zhaijack opened a new pull request #1550: Issue #1517: make 
getLastConfirmedEntry in ManagedLedgerImpl return real LAC
URL: https://github.com/apache/incubator-pulsar/pull/1550
 
 
   ### Motivation
   
   In ManagedLedgerImpl,  getLastConfirmedEntry() uses lastConfirmedEntry, 
which is set to <ledgerId>:-1, when a new new ledger is created (as happens on 
restart). This will cause reader.hasMessageAvailable working working wrongly. 
   
   ### Modifications
   
   In ManagedLedgerImpl, change getLastConfirmedEntry to bypass empty ledgers, 
and find last ledger with Message, if possible.
   
   ### Result
   
   getLastConfirmedEntry working fine. Ut in TopicReaderTest pass.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to