Skip to content

Commit

Permalink
fix lock release before deletion is completed
Browse files Browse the repository at this point in the history
Signed-off-by: bansvaru <[email protected]>
  • Loading branch information
linuxpi committed Oct 13, 2023
1 parent 6c02261 commit 22e940c
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -881,8 +881,9 @@ public void onFailure(Exception e) {
}
}
);
} finally {
} catch (Exception e) {
deleteStaleMetadataRunning.set(false);
throw e;
}
}

Expand Down Expand Up @@ -952,7 +953,7 @@ private void deleteStalePaths(String clusterName, String clusterUUID, List<Strin
public void deleteStaleClusterUUIDs(ClusterState clusterState, ClusterMetadataManifest committedManifest) {
threadpool.executor(ThreadPool.Names.REMOTE_PURGE).execute(() -> {
String clusterName = clusterState.getClusterName().value();
logger.info("Deleting stale cluster UUIDs data from remote [{}]", clusterName);
logger.debug("Deleting stale cluster UUIDs data from remote [{}]", clusterName);
Set<String> allClustersUUIDsInRemote;
try {
allClustersUUIDsInRemote = new HashSet<>(getAllClusterUUIDs(clusterState.getClusterName().value()));
Expand Down

0 comments on commit 22e940c

Please sign in to comment.