diff --git a/pom.xml b/pom.xml index b605d719..5dd2f83f 100644 --- a/pom.xml +++ b/pom.xml @@ -28,7 +28,7 @@ org.jenkins-ci.plugins plugin - 3.54 + 4.1 org.jenkins-ci.plugins.workflow @@ -64,36 +64,39 @@ 3.5 -SNAPSHOT - 2.138.4 + 2.176.4 8 false true 3.0 - 3.7.0 - 2.7 - 2.20 - 2.2.6 + + + + io.jenkins.tools.bom + bom-2.176.x + 9 + import + pom + + + org.jenkins-ci.plugins.workflow workflow-step-api - ${workflow-step-api-plugin.version} org.jenkins-ci.plugins.workflow workflow-api - 2.36 org.jenkins-ci.plugins scm-api - ${scm-api-plugin.version} org.jenkins-ci.plugins script-security - 1.39 @@ -104,110 +107,74 @@ org.jenkins-ci.plugins.workflow workflow-step-api - ${workflow-step-api-plugin.version} tests test org.mockito mockito-core - 1.9.5 test - - - org.hamcrest - hamcrest-core - - org.jenkins-ci.plugins structs - 1.18 test org.jenkins-ci.plugins.workflow workflow-cps - 2.42 test org.jenkins-ci.plugins.workflow workflow-scm-step - ${workflow-scm-step-plugin.version} test org.jenkins-ci.plugins scm-api - ${scm-api-plugin.version} tests test org.jenkins-ci.plugins.workflow workflow-durable-task-step - 2.9 test org.jenkins-ci.plugins.workflow workflow-job - 2.36 test org.jenkins-ci.plugins.workflow workflow-basic-steps - 2.4 test org.jenkins-ci.plugins git - ${git-plugin.version} test - - - commons-codec - commons-codec - - - org.jenkins-ci - annotation-indexer - - org.jenkins-ci.plugins git - ${git-plugin.version} tests test - - - org.jenkins-ci - annotation-indexer - - org.jenkins-ci.plugins mailer - 1.19 test org.jenkins-ci.plugins junit - 1.20 test org.jenkins-ci.plugins pipeline-build-step - 2.5 test diff --git a/src/main/java/org/jenkinsci/plugins/workflow/support/actions/LogActionImpl.java b/src/main/java/org/jenkinsci/plugins/workflow/support/actions/LogActionImpl.java index 9fe19f73..de84a32e 100644 --- a/src/main/java/org/jenkinsci/plugins/workflow/support/actions/LogActionImpl.java +++ b/src/main/java/org/jenkinsci/plugins/workflow/support/actions/LogActionImpl.java @@ -159,6 +159,7 @@ private File getLogFile() throws IOException { /** * Used from console.jelly to write annotated log to the given output. */ + @SuppressFBWarnings(value = "RV_RETURN_VALUE_IGNORED", justification = "Deprecated and unused code, only exists for compatibility with old builds") @Restricted(DoNotUse.class) // Jelly public void writeLogTo(long offset, XMLOutput out) throws IOException { AnnotatedLargeText l = getLogText(); diff --git a/src/main/java/org/jenkinsci/plugins/workflow/support/actions/LogStorageAction.java b/src/main/java/org/jenkinsci/plugins/workflow/support/actions/LogStorageAction.java index 7bb5b4be..e287e661 100644 --- a/src/main/java/org/jenkinsci/plugins/workflow/support/actions/LogStorageAction.java +++ b/src/main/java/org/jenkinsci/plugins/workflow/support/actions/LogStorageAction.java @@ -67,7 +67,15 @@ private LogStorageAction(FlowNode node) { */ @Restricted(DoNotUse.class) // Jelly public void writeLogTo(long offset, XMLOutput out) throws IOException { - getLogText().writeHtmlTo(offset, out.asWriter()); + // Similar to Run#writeWholeLogTo but terminates even if node.isActive(). Adapated from WorkflowRun.writeLogTo. + long pos = offset; + while (true) { + long pos2 = getLogText().writeHtmlTo(pos, out.asWriter()); + if (pos2 <= pos) { + break; + } + pos = pos2; + } } /**