poorbarcode commented on code in PR #26184:
URL: https://github.com/apache/pulsar/pull/26184#discussion_r3575654902
##########
managed-ledger/src/main/java/org/apache/bookkeeper/mledger/impl/ManagedCursorImpl.java:
##########
@@ -1275,6 +1275,12 @@ public int
getNonContiguousDeletedMessagesRangeSerializedSize() {
@Override
public long getEstimatedSizeSinceMarkDeletePosition() {
+ Position markDeletePosition = this.markDeletePosition;
+ Position lastPosition = ledger.getLastPosition();
+ if (markDeletePosition == null ||
markDeletePosition.compareTo(lastPosition) >= 0) {
Review Comment:
Sorry, I made a mistake. The correct condition should be as follows:
1. `isMarkDeletePositionOnEmptyCurrentLedger(markDeletePosition)`
2. `managedLedger.ledgerExists(ledger.latestLedger)`
--
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]