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

Show job link and charts even if latest build does not contain results

      I have a build that in some cases is avoided - logs are not produced.

      I would like to be able to compensate reports generation, so no matter if new results are collected, the graph and links are displayed. Currenly only a build that records issues is showing both of those.

      I tried to compensate it by generating report with empty issues collection but then the graph drops to 0

       

      Example - every second build generates report:

      pipeline {
          agent any
          stages {
              stage ('recordIssues') {
                  when { expression { env.BUILD_NUMBER.toBigInteger().mod( 2 ) == 0 } }
                  steps {
                      recordIssues(
                          tools: [
                              intel(pattern: "logs\\**\\*.*"), 
                          ]
                      )
                  }
              }        stage ('compensate') {
                  when { expression { env.BUILD_NUMBER.toBigInteger().mod( 2 ) != 0 } }
                  steps {
                      echo "don't know how..."
                  }
              }
          }    
      }
      

          [JENKINS-57636] Show job link and charts even if latest build does not contain results

          Jakub Pawlinski created issue -

          Ulli Hafner added a comment -

          Which links do you mean? The link on the job page or on the build page?

          Ulli Hafner added a comment - Which links do you mean? The link on the job page or on the build page?

          on the job page

          Jakub Pawlinski added a comment - on the job page
          Ulli Hafner made changes -
          Summary Original: Generate graphs/links when report not generated New: Show job link and charts even if latest build does not contain results.

          Ulli Hafner added a comment -

          I'm not sure if this is technically possible as the action that shows the links and the trend is created within the action of the build results. If there is no action for a build this does not work. Maybe we should have a flag in recordIssues that creates an empty build action.

          Ulli Hafner added a comment - I'm not sure if this is technically possible as the action that shows the links and the trend is created within the action of the build results. If there is no action for a build this does not work. Maybe we should have a flag in recordIssues that creates an empty build action.
          Ulli Hafner made changes -
          Summary Original: Show job link and charts even if latest build does not contain results. New: Show job link and charts even if latest build does not contain results

          possibility of empty build action would do just right

          Jakub Pawlinski added a comment - possibility of empty build action would do just right
          Ulli Hafner made changes -
          Assignee Original: Ulli Hafner [ drulli ]
          Labels New: help-wanted
          Ulli Hafner made changes -
          Link New: This issue is duplicated by JENKINS-56083 [ JENKINS-56083 ]
          Ulli Hafner made changes -
          Labels Original: help-wanted New: hacktoberfest help-wanted newbie-friendly

            jay_vts Jayanth
            quas Jakub Pawlinski
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated: