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

Fail fast - When one parallel job fails, fail the flow job (and optionally cancel the rest)

    • Icon: New Feature New Feature
    • Resolution: Unresolved
    • Icon: Major Major
    • build-flow-plugin
    • None

      Add option to fail the flow build when a parallel job fails.

      Build flow config on orcastrator job:

      build("Build and publish artifacts")
      parallel (
          {
              build("Slow tests 1")
          },
          {
              build("Slow tests 2")
          },
          {
              build("Fast tests 1")
          },
          {
              build("Fast tests 2")
          }
      )
      

      Lets say "Fast tests 1" fails on formatting check. Then the whole build should fail and make the executor will be available for other jobs. No need to finish "Slow tests 1", "Slow tests 2" and "Fast tests 2"

      Might be related to JENKINS-18177 ("Allow to cancel both the flow and all running builds").

      This feature is also mentioned in a comment, sep 13 2012:
      https://wiki.jenkins-ci.org/display/JENKINS/Build+Flow+Plugin?focusedCommentId=63931160#comment-63931160

            Unassigned Unassigned
            hnygard Hallvard Nygård
            Votes:
            18 Vote for this issue
            Watchers:
            16 Start watching this issue

              Created:
              Updated: