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

If a failure happens outside of parallel branch it isn't shown in a stage

    XMLWordPrintable

Details

    Description

      Solution

      • Fold in steps to their nearest stage so that they appear in the step list
      • When JENKINS-39658 is fixed the error log will be appended to the step

      Original request
      Blue ocean shows parallel branches as separate "nodes" (circles) on the stage graph.

      This means that if a build failure happens outside of a parallel branch, you end up with all green circles but a failed build.

      See the attached

      This is for the simple pipeline:

      node {
          
          stage('first') {
              sh "echo 42"
          }
          
          stage('par') {
              parallel(
                  "left" : {
                      sh "echo 42"   
                   }, 
                   "right" : {
                      sh "echo 43"
                   }
                  
                  
              )
              
              error "it's all bad"
              
          }
          
      }
      

      What this should do:

      if there are steps outside of parallel branches, show them as a node (circle) directly under the stage name (and if any steps fail, that node shows as failed).

      Attachments

        Issue Links

          Activity

            hrmpw Patrick Wolf added a comment -

            Do we have some negative tests that can fail a build more disastrously than an error step? At least until we have JENKINS-35308 implemetend

            hrmpw Patrick Wolf added a comment - Do we have some negative tests that can fail a build more disastrously than an error step? At least until we have JENKINS-35308 implemetend
            michaelneale Michael Neale added a comment -

            hrmpw yeah JENKINS-35308 seems a bit of a long shot right now.

            michaelneale Michael Neale added a comment - hrmpw yeah JENKINS-35308 seems a bit of a long shot right now.
            hrmpw Patrick Wolf added a comment -

            Why do you say it's a long shot, michaelneale? It's something we flagged to do for improving Pipeline and I think this one is pretty important, even with PMD. If any step fails on the backend we need to make sure the error reporting is good.

            hrmpw Patrick Wolf added a comment - Why do you say it's a long shot, michaelneale ? It's something we flagged to do for improving Pipeline and I think this one is pretty important, even with PMD. If any step fails on the backend we need to make sure the error reporting is good.
            jamesdumay James Dumay added a comment - - edited

            hrmpw if the archive step fails because there are no inputs that fails terribly too (with a stack trace). There are many steps that exhibit similar behaviour. If we can have beautiful error reports like JENKINS-35308 for all the steps I would sleep better at night

            jamesdumay James Dumay added a comment - - edited hrmpw if the archive step fails because there are no inputs that fails terribly too (with a stack trace). There are many steps that exhibit similar behaviour. If we can have beautiful error reports like JENKINS-35308 for all the steps I would sleep better at night
            michaelneale Michael Neale added a comment -

            hrmpw from conversations with KK, it wasn't relised at first how hard it would be to implement. As the saying goes "we do these things not because they are easy, but because we thought they would be easy"

            michaelneale Michael Neale added a comment - hrmpw from conversations with KK, it wasn't relised at first how hard it would be to implement. As the saying goes "we do these things not because they are easy, but because we thought they would be easy"

            People

              Unassigned Unassigned
              michaelneale Michael Neale
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: