From 75fce407c09719573914f3cb204200f6bd708f45 Mon Sep 17 00:00:00 2001 From: "AO Industries, Inc" Date: Wed, 20 Sep 2023 19:16:57 +0000 Subject: [PATCH] abortOnUnreadyDependency is now a Jenkins parameter to allow forcing the immediate build of a project even when dependencies are not ready. This is useful to force a build that needs to go out immediately. --- Jenkinsfile | 16 ++++++++-------- all | 2 +- bom | 2 +- book/Jenkinsfile | 16 ++++++++-------- model | 2 +- servlet | 2 +- style | 2 +- taglib | 2 +- view | 2 +- 9 files changed, 23 insertions(+), 23 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index c595efc..40eb9f2 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -60,10 +60,6 @@ def upstreamProjects = [ * 'book/Jenkinsfile' -> 'book' * * 'devel/Jenkinsfile' -> 'devel' * * * - * abortOnUnreadyDependency Aborts the build when any dependency is queued, building, * - * or unsuccessful. * - * Defaults to true * - * * * disableSubmodules Disables checkout of Git submodules. * * Defaults to true * * * @@ -169,9 +165,6 @@ if (!binding.hasVariable('projectDir')) { } binding.setVariable('projectDir', projectDir) } -if (!binding.hasVariable('abortOnUnreadyDependency')) { - binding.setVariable('abortOnUnreadyDependency', true) -} if (!binding.hasVariable('disableSubmodules')) { binding.setVariable('disableSubmodules', true) } @@ -584,6 +577,13 @@ pipeline { defaultValue: "$buildPriority", description: """Specify the priority of this build. Defaults to project's depth in the upstream project graph.""" + ) + booleanParam( + name: 'abortOnUnreadyDependency', + defaultValue: true, + description: """Aborts the build when any dependency is queued, building, or unsuccessful. +Defaults to true and will typically only be false to push a new version of a project out immediately. +May also want to set BuildPriority to \"1\" to put at the top of the build queue.""" ) booleanParam( name: 'requireLastBuild', @@ -603,7 +603,7 @@ or any build that adds or removes build artifacts.""" stage('Check Ready') { when { expression { - return abortOnUnreadyDependency + return params.abortOnUnreadyDependency } } steps { diff --git a/all b/all index f96ea81..2d03ce0 160000 --- a/all +++ b/all @@ -1 +1 @@ -Subproject commit f96ea8126208576326a710ba99b941fa4a625460 +Subproject commit 2d03ce0e4af9ff0ea0a5b87ab52a55847347038e diff --git a/bom b/bom index a8055c0..dce6f4c 160000 --- a/bom +++ b/bom @@ -1 +1 @@ -Subproject commit a8055c01b6917cdb9c210dbee5f5239d089be060 +Subproject commit dce6f4cb488138980a19b18899ca5e98b3ca620b diff --git a/book/Jenkinsfile b/book/Jenkinsfile index b2da57a..5768896 100644 --- a/book/Jenkinsfile +++ b/book/Jenkinsfile @@ -74,10 +74,6 @@ def upstreamProjects = [ * 'book/Jenkinsfile' -> 'book' * * 'devel/Jenkinsfile' -> 'devel' * * * - * abortOnUnreadyDependency Aborts the build when any dependency is queued, building, * - * or unsuccessful. * - * Defaults to true * - * * * disableSubmodules Disables checkout of Git submodules. * * Defaults to true * * * @@ -183,9 +179,6 @@ if (!binding.hasVariable('projectDir')) { } binding.setVariable('projectDir', projectDir) } -if (!binding.hasVariable('abortOnUnreadyDependency')) { - binding.setVariable('abortOnUnreadyDependency', true) -} if (!binding.hasVariable('disableSubmodules')) { binding.setVariable('disableSubmodules', true) } @@ -598,6 +591,13 @@ pipeline { defaultValue: "$buildPriority", description: """Specify the priority of this build. Defaults to project's depth in the upstream project graph.""" + ) + booleanParam( + name: 'abortOnUnreadyDependency', + defaultValue: true, + description: """Aborts the build when any dependency is queued, building, or unsuccessful. +Defaults to true and will typically only be false to push a new version of a project out immediately. +May also want to set BuildPriority to \"1\" to put at the top of the build queue.""" ) booleanParam( name: 'requireLastBuild', @@ -617,7 +617,7 @@ or any build that adds or removes build artifacts.""" stage('Check Ready') { when { expression { - return abortOnUnreadyDependency + return params.abortOnUnreadyDependency } } steps { diff --git a/model b/model index 84a4312..15bb74d 160000 --- a/model +++ b/model @@ -1 +1 @@ -Subproject commit 84a4312a727bda762ac75b3741ad74f5425e4190 +Subproject commit 15bb74df5ef6fdd0acf08921d3135f521c670579 diff --git a/servlet b/servlet index a0eeb3d..fcfae01 160000 --- a/servlet +++ b/servlet @@ -1 +1 @@ -Subproject commit a0eeb3d1c9ed8abf2d8af6572e81c0fd6d192f14 +Subproject commit fcfae0199693ae35807747b8ee73246f4c9ea82b diff --git a/style b/style index f2659c3..bb752c5 160000 --- a/style +++ b/style @@ -1 +1 @@ -Subproject commit f2659c3a7aecbd79a731caf7f35312ed3b3ad85d +Subproject commit bb752c5301a92a2a09186f833a043b2e84179f25 diff --git a/taglib b/taglib index b0adba5..5a3ce52 160000 --- a/taglib +++ b/taglib @@ -1 +1 @@ -Subproject commit b0adba53826bd3e41ecccf0d6f7547f8b38d914d +Subproject commit 5a3ce527ef5ad98e374c0f0e689601e32bf6bd0e diff --git a/view b/view index 3d439af..5014546 160000 --- a/view +++ b/view @@ -1 +1 @@ -Subproject commit 3d439af63f32faa92a4b9a341a2a9461900de62c +Subproject commit 5014546a550a8f8ee3af97ecbdb63c7b73a2571b