You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@uima.apache.org by re...@apache.org on 2022/02/18 09:54:56 UTC

[uima-build-jenkins-shared-library] branch UIMA-6419-Add-per-build-agent-override-parameter created (now 9635f1e)

This is an automated email from the ASF dual-hosted git repository.

rec pushed a change to branch UIMA-6419-Add-per-build-agent-override-parameter
in repository https://gitbox.apache.org/repos/asf/uima-build-jenkins-shared-library.git.


      at 9635f1e  [UIMA-6419] Add per-build agent override parameter

This branch includes the following new commits:

     new 9635f1e  [UIMA-6419] Add per-build agent override parameter

The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


[uima-build-jenkins-shared-library] 01/01: [UIMA-6419] Add per-build agent override parameter

Posted by re...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

rec pushed a commit to branch UIMA-6419-Add-per-build-agent-override-parameter
in repository https://gitbox.apache.org/repos/asf/uima-build-jenkins-shared-library.git

commit 9635f1e9171b59162ed40645ca283586af351aea
Author: Richard Eckart de Castilho <re...@apache.org>
AuthorDate: Fri Feb 18 10:54:51 2022 +0100

    [UIMA-6419] Add per-build agent override parameter
    
    - Added agent override option
---
 vars/defaultPipeline.groovy | 22 +++++++++++++---------
 1 file changed, 13 insertions(+), 9 deletions(-)

diff --git a/vars/defaultPipeline.groovy b/vars/defaultPipeline.groovy
index ac82d17..68a7f21 100644
--- a/vars/defaultPipeline.groovy
+++ b/vars/defaultPipeline.groovy
@@ -21,8 +21,19 @@ def call(body) {
   def config = createConfiguration(body)
     
   pipeline {
+    parameters {
+      string(
+        name: 'extraMavenArguments',
+        defaultValue: config.extraMavenArguments,
+        description: "Extra arguments to be passed to maven (for testing; overrides only current build)")
+      string(
+        name: 'agentLabel',
+        defaultValue: config.agentLabel,
+        description: "Eligible agents (in case a build keeps running on a broken agent; overrides only current build)")
+    }
+
     agent {
-      label config.agentLabel
+      label params.agentLabel ?: config.agentLabel
     }
   
     tools {
@@ -39,14 +50,7 @@ def call(body) {
       // Seems not to be working reliably yet: https://issues.jenkins-ci.org/browse/JENKINS-48556
       // timestamps()
     }
-    
-    parameters {
-      string(
-        name: 'extraMavenArguments',
-        defaultValue: config.extraMavenArguments,
-        description: "Extra arguments to be passed to maven (for testing; overrides only current build)")
-    }
-  
+      
     stages {
       // Display information about the build environemnt. This can be useful for debugging
       // build issues.