Dear Community, I hope this message finds you well. I am writing to discuss a modification to the behavior of deleting the current ledger. As you may know, in Pulsar, the current ledger cannot be deleted because it may still be written to. However, there is an exception. When the current ledger is rolled over, but no new messages are written, the current ledger does not change. In this case, the current ledger will not be written to, but it is also not deleted.
This can be confusing for users, especially when they configure `managedLedgerMaxLedgerRolloverTimeMinutes` and `retentionTimeInMinutes`. They expect the current ledger to roll over and then be deleted after `managedLedgerMaxLedgerRolloverTimeMinutes` and `retentionTimeInMinutes`. However, in reality, while the current ledger does rollover, it is not deleted. The purpose of this discussion is to consider deleting the current ledger when it is rolled over. The specific implementation can be found at https://github.com/apache/pulsar/pull/22034. Looking forward to a productive discussion. Best Regards, xiangying