Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions docs/changelog/84089.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
pr: 84089
summary: Preserve context in `snapshotDeletionListeners`
area: Snapshot/Restore
type: bug
issues:
- 84036
Original file line number Diff line number Diff line change
Expand Up @@ -2289,7 +2289,8 @@ private static boolean isWritingToRepository(SnapshotsInProgress.Entry entry) {
}

private void addDeleteListener(String deleteUUID, ActionListener<Void> listener) {
snapshotDeletionListeners.computeIfAbsent(deleteUUID, k -> new CopyOnWriteArrayList<>()).add(listener);
snapshotDeletionListeners.computeIfAbsent(deleteUUID, k -> new CopyOnWriteArrayList<>())
.add(ContextPreservingActionListener.wrapPreservingContext(listener, threadPool.getThreadContext()));
}

/**
Expand Down