Skip to content

Commit

Permalink
[fix] [broker] Fix race-condition causing repeated delete topic
Browse files Browse the repository at this point in the history
  • Loading branch information
poorbarcode committed Oct 28, 2024
1 parent 485792d commit 60d809b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -398,10 +398,11 @@ private static ManagedLedgerInfo updateMLInfoTimestamp(ManagedLedgerInfo info) {
}

private static MetaStoreException getException(Throwable t) {
if (t.getCause() instanceof MetadataStoreException.BadVersionException) {
Throwable actEx = FutureUtil.unwrapCompletionException(t);
if (actEx instanceof MetadataStoreException.BadVersionException) {
return new ManagedLedgerException.BadVersionException(t.getMessage());
} else {
return new MetaStoreException(t);
return new MetaStoreException(actEx);
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1565,7 +1565,6 @@ public void deleteLedgerComplete(Object ctx) {
}).whenComplete((value, ex) -> {
if (ex != null) {
log.error("[{}] Error deleting topic", topic, ex);
unfenceTopicToResume();
}
});

Expand Down

0 comments on commit 60d809b

Please sign in to comment.