From b96dd41b428bc7037cc7fc0d79cde5ce6ebe6493 Mon Sep 17 00:00:00 2001 From: Robert Haschke Date: Fri, 24 Jan 2020 13:33:22 +0100 Subject: [PATCH] fix orchestration Cancelling a single job stops the whole orchestration because the CancellationException that is thrown when done.get() is called, was not caught. --- templates/ci-deploy/orchestration.template | 2 +- templates/ci/orchestration.template | 2 +- templates/citk/orchestration.template | 2 +- templates/toolkit/orchestration.template | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/templates/ci-deploy/orchestration.template b/templates/ci-deploy/orchestration.template index 07cd7eb47..6efe3fb2f 100644 --- a/templates/ci-deploy/orchestration.template +++ b/templates/ci-deploy/orchestration.template @@ -55,7 +55,7 @@ variables: def popBuild() { done = running.find { build -> build.isDone() } - if (done) { + if (done && !done.isCancelled()) { running.remove(done) return done.get() } diff --git a/templates/ci/orchestration.template b/templates/ci/orchestration.template index 9744b2f92..9bcfe5e50 100644 --- a/templates/ci/orchestration.template +++ b/templates/ci/orchestration.template @@ -70,7 +70,7 @@ variables: def popBuild() { done = running.find { build -> build.isDone() } - if (done) { + if (done && !done.isCancelled()) { running.remove(done) return done.get() } diff --git a/templates/citk/orchestration.template b/templates/citk/orchestration.template index dc5d9f5f8..3c834c290 100644 --- a/templates/citk/orchestration.template +++ b/templates/citk/orchestration.template @@ -78,7 +78,7 @@ variables: def popBuild() { done = running.find { build -> build.isDone() } - if (done) { + if (done && !done.isCancelled()) { running.remove(done) return done.get() } diff --git a/templates/toolkit/orchestration.template b/templates/toolkit/orchestration.template index 5550645a0..3dce992c7 100644 --- a/templates/toolkit/orchestration.template +++ b/templates/toolkit/orchestration.template @@ -69,7 +69,7 @@ variables: def popBuild() { done = running.find { build -> build.isDone() } - if (done) { + if (done && !done.isCancelled()) { running.remove(done) return done.get() } -- 2.17.1