diff --git a/src/main/java/org/jenkinsci/plugins/workflow/job/WorkflowRun.java b/src/main/java/org/jenkinsci/plugins/workflow/job/WorkflowRun.java index dcce8d4c..deb05e16 100644 --- a/src/main/java/org/jenkinsci/plugins/workflow/job/WorkflowRun.java +++ b/src/main/java/org/jenkinsci/plugins/workflow/job/WorkflowRun.java @@ -547,6 +547,7 @@ private String key() { /** Hack to allow {@link #execution} to use an {@link Owner} referring to this run, even when it has not yet been loaded. */ @Override public void reload() throws IOException { + LOGGER.fine(() -> "Adding " + key() + " to LOADING_RUNS"); synchronized (LOADING_RUNS) { LOADING_RUNS.put(key(), this); } @@ -612,6 +613,7 @@ private String key() { } } finally { // Ensure the run is ALWAYS removed from loading even if something failed, so threads awaken. checkouts(null); // only for diagnostics + LOGGER.fine(() -> "Removing " + key() + " from LOADING_RUNS"); synchronized (LOADING_RUNS) { LOADING_RUNS.remove(key()); // or could just make the value type be WeakReference LOADING_RUNS.notifyAll();