Skip to content

Commit

Permalink
fix the race of delete subscription and delete topic (#12240)
Browse files Browse the repository at this point in the history
(cherry picked from commit 9137e6b)
  • Loading branch information
ZhangJian He authored and codelipenghui committed Oct 26, 2021
1 parent 83d941f commit f07a87d
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1020,6 +1020,11 @@ public void deleteCursorFailed(ManagedLedgerException exception, Object ctx) {
log.debug("[{}][{}] Error deleting cursor for subscription",
topic, subscriptionName, exception);
}
if (exception instanceof ManagedLedgerException.ManagedLedgerNotFoundException) {
unsubscribeFuture.complete(null);
lastActive = System.nanoTime();
return;
}
unsubscribeFuture.completeExceptionally(new PersistenceException(exception));
}
}, null);
Expand Down

0 comments on commit f07a87d

Please sign in to comment.