Skip to content

Commit 6bcaead

Browse files
committed
Comment on null deleteUUID
1 parent 8151d5d commit 6bcaead

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

server/src/main/java/org/elasticsearch/snapshots/SnapshotsService.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1545,6 +1545,8 @@ private void notifyAbortedByDeletion(Snapshot snapshot) {
15451545

15461546
private void completeOrAddDeleteListener(@Nullable String deleteUUID, ActionListener<Void> listener) {
15471547
if (deleteUUID == null) {
1548+
// if the deletion only aborted snapshots that had not started to write to the repository then no cleanup is required, these
1549+
// snapshots have already been removed from the cluster state, and hence we can complete the listener immediately:
15481550
listener.onResponse(null);
15491551
} else {
15501552
snapshotDeletionListeners.computeIfAbsent(deleteUUID, k -> new CopyOnWriteArrayList<>())

0 commit comments

Comments
 (0)