eolivelli opened a new issue #8677:
URL: https://github.com/apache/pulsar/issues/8677
**Describe the bug**
It looks like that when a topic remains empty due to message retention, it
is not possible to ask for the lastMessageId
I see these errors in the HTTP server logs:
> "GET /admin/v2/persistent/XXX/YYY/ZZZZ/lastMessageId HTTP/1.1" 500 53 "-"
"Pulsar-Java-v2.6.2" 2
And this line:
> Error opening ledger for reading at position 178974309:7 -
org.apache.bookkeeper.mledger.ManagedLedgerException$NonRecoverableLedgerException:
No such ledger exists on Metadata Server
**To Reproduce**
I don't have a reproducer yet, I have only seen this issue in production.
**Expected behavior**
Some non-error code should be returned to the client
** System (please complete the following information):**
- Linux, JDK14, both Pulsar Broker and Pulsar Client
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]