From 7f1363690fc52ef78c78a9ff1b4fc4b87d9a0b39 Mon Sep 17 00:00:00 2001 From: Mark Waite Date: Sat, 1 Oct 2022 08:25:52 -0600 Subject: [PATCH 1/5] Remove unused exclusion --- pom.xml | 6 ------ 1 file changed, 6 deletions(-) diff --git a/pom.xml b/pom.xml index c2fcf616..89104972 100644 --- a/pom.xml +++ b/pom.xml @@ -122,12 +122,6 @@ org.jenkins-ci.plugins matrix-project true - - - javax.annotation - javax.annotation-api - - org.jenkins-ci.plugins From 5b22c6edc179780cd4e504eb9fbbce32fb5e59a9 Mon Sep 17 00:00:00 2001 From: Mark Waite Date: Sat, 1 Oct 2022 08:26:10 -0600 Subject: [PATCH 2/5] Require Jenkins 2.346.3 or newer --- pom.xml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pom.xml b/pom.xml index 89104972..463cde4b 100644 --- a/pom.xml +++ b/pom.xml @@ -10,7 +10,7 @@ 4.1.1 -SNAPSHOT jenkinsci/priority-sorter-plugin - 2.332.4 + 2.346.3 6.50.0 Max Low @@ -49,7 +49,7 @@ io.jenkins.tools.bom - bom-2.332.x + bom-2.346.x 1607.va_c1576527071 import pom From 15c58fa6d5e2e131efb7c88da44c4999959e95ae Mon Sep 17 00:00:00 2001 From: Mark Waite Date: Sat, 1 Oct 2022 08:26:24 -0600 Subject: [PATCH 3/5] Test with nested view plugin 1.26 --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index 463cde4b..24b9352f 100644 --- a/pom.xml +++ b/pom.xml @@ -158,7 +158,7 @@ org.jenkins-ci.plugins nested-view - 1.24 + 1.26 test From 480be8877e0de0340abacdb6e2f5a10af89bc917 Mon Sep 17 00:00:00 2001 From: Mark Waite Date: Sat, 1 Oct 2022 10:34:34 -0600 Subject: [PATCH 4/5] Update Jenkinsfile to match new min version --- Jenkinsfile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 648a6b35..87f0633c 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -3,7 +3,7 @@ /* `buildPlugin` step provided by: https://github.com/jenkins-infra/pipeline-library */ buildPlugin(failFast: false, configurations: [ - [platform: 'linux', jdk: '17', jenkins: '2.342'], - [platform: 'linux', jdk: '11'], - [platform: 'windows', jdk: '8' ], + [platform: 'linux', jdk: '17', jenkins: '2.371' ], + [platform: 'linux', jdk: '11', jenkins: '2.361.1'], + [platform: 'windows', jdk: '8' ], ]) From 48c09ed6a7999337abee9b38fbb19a57f60bd131 Mon Sep 17 00:00:00 2001 From: Mark Waite Date: Sat, 1 Oct 2022 11:15:05 -0600 Subject: [PATCH 5/5] Exclude two new spotbugs warnings Reported when compiling with Java 17 and Jenkins 2.371 --- .../java/jenkins/advancedqueue/RunExclusiveThrottler.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/main/java/jenkins/advancedqueue/RunExclusiveThrottler.java b/src/main/java/jenkins/advancedqueue/RunExclusiveThrottler.java index 99039a81..e955dd1a 100644 --- a/src/main/java/jenkins/advancedqueue/RunExclusiveThrottler.java +++ b/src/main/java/jenkins/advancedqueue/RunExclusiveThrottler.java @@ -1,5 +1,7 @@ package jenkins.advancedqueue; +import edu.umd.cs.findbugs.annotations.SuppressFBWarnings; + import hudson.Extension; import hudson.model.Queue.Item; import hudson.model.Run; @@ -18,7 +20,9 @@ public class RunExclusiveThrottler { static private List exclusiveJobs = Collections.synchronizedList(new ArrayList()); + @SuppressFBWarnings(value = "ST_WRITE_TO_STATIC_FROM_INSTANCE_METHOD", justification = "Low risk") static private int exclusiveJobGroupId = -1; + @SuppressFBWarnings(value = "ST_WRITE_TO_STATIC_FROM_INSTANCE_METHOD", justification = "Low risk") static private String exclusiveJobName = ""; static PriorityConfigurationCallback dummyCallback = new PriorityConfigurationCallback() {