Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-35647

Unable to abort parallel pipeline when failfast is used

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: Minor Minor
    • workflow-cps-plugin
    • None
    • Jenkins v2.8

      I've got a Jenkinsfile which first prepares 7 difficult tasks and then calls them in parallel on 7 executors (5 linux builds with different configurations and 2 windows builds). I also use failFast: true to ensure when any of the branches fails the whole build would fail, without waiting for other branches to complete.

      However, when one branch fails I can see that all branches in log output get "branch <name> failed", however even though all branches have completed, Jenkins still shows my build as being in progress. Even worse, if I click the x button to abort the build, nothing happens (the build continues to run, even though no executor is used and nothing is really happening). If I restart the Jenkins, then this build is resumed after restart, however no executor is consumed and nothing really happens, except Jenkins displays this build as being in progress.

      Here is the thread dump of a zombie build which failed long time ago, yet Jenkins still displays it as "in progress", even though no executor is consumed by this build:

      Thread #88
      at DSL.sh(Native Method)
      at WorkflowScript.linuxBuild(WorkflowScript:59)
      at DSL.dir(Native Method)
      at WorkflowScript.linuxBuild(WorkflowScript:54)
      at DSL.ws(Native Method)
      at WorkflowScript.linuxBuild(WorkflowScript:44)
      at WorkflowScript.run(WorkflowScript:132)
      at DSL.node(Native Method)
      at WorkflowScript.run(WorkflowScript:131)
      at DSL.parallel(Native Method)
      at WorkflowScript.run(WorkflowScript:171)
      Thread #82
      at DSL.sh(Native Method)
      at WorkflowScript.linuxBuild(WorkflowScript:59)
      at DSL.dir(Native Method)
      at WorkflowScript.linuxBuild(WorkflowScript:54)
      at DSL.ws(Native Method)
      at WorkflowScript.linuxBuild(WorkflowScript:44)
      at WorkflowScript.run(WorkflowScript:137)
      at DSL.node(Native Method)
      at WorkflowScript.run(WorkflowScript:136)
      Thread #86
      at DSL.sh(Native Method)
      at WorkflowScript.linuxBuild(WorkflowScript:59)
      at DSL.dir(Native Method)
      at WorkflowScript.linuxBuild(WorkflowScript:54)
      at DSL.ws(Native Method)
      at WorkflowScript.linuxBuild(WorkflowScript:44)
      at WorkflowScript.run(WorkflowScript:142)
      at DSL.node(Native Method)
      at WorkflowScript.run(WorkflowScript:141)
      Thread #84
      at DSL.sh(Native Method)
      at WorkflowScript.linuxBuild(WorkflowScript:59)
      at DSL.dir(Native Method)
      at WorkflowScript.linuxBuild(WorkflowScript:54)
      at DSL.ws(Native Method)
      at WorkflowScript.linuxBuild(WorkflowScript:44)
      at WorkflowScript.run(WorkflowScript:147)
      at DSL.node(Native Method)
      at WorkflowScript.run(WorkflowScript:146)

      If required, I can provide my Jenkinsfile script.

            recena Manuel Recena Soto
            dodoent Nenad Miksa
            Votes:
            2 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: