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

findbugs plugin does not fail a pipeline job as requested

    Details

    • Type: Bug
    • Status: Resolved (View Workflow)
    • Priority: Major
    • Resolution: Cannot Reproduce
    • Component/s: findbugs-plugin
    • Labels:
      None
    • Environment:
    • Similar Issues:

      Description

      Within a pipeline, I have configured findbugs report :

      deleteDir()
      checkout scm
      sh "mvn clean install"

      findbugs defaultEncoding: '', excludePattern: '', healthy: '', includePattern: '', pattern: '**/findbugsXml.xml', failedTotalHigh: '0', unHealthy: ''

      The report is produced correctly. But if a 'High' issue appears, the build is not aborted, and not set to status 'failed'.

      In the console log, findbugs reports:

      [FINDBUGS] Plug-in Result: Failed - <a href="findbugsResult">5 warnings</a> of <a href="findbugsResult/HIGH">priority High</a> exceed the threshold of 0 by 5

      but the build just proceeds as if the report would not find anything.

        Attachments

          Activity

          tobias_hd Tobias Munk created issue -
          tobias_hd Tobias Munk made changes -
          Field Original Value New Value
          Description Within a pipeline, I have configured findbugs report :

          deleteDir()
          checkout scm
          sh "mvn clean install"

          findbugs defaultEncoding: '', excludePattern: '', healthy: '', includePattern: '', pattern: '**/findbugsXml.xml', failedTotalHigh: '0', unHealthy: ''

          The report is produced correctly. But if a 'High' issue appears, the build is not aborted, and not set to status 'failed'.

          In the console log, findbugs reports:

           
          [FINDBUGS] Plug-in Result: Failed - <a href="findbugsResult">5 warnings</a> of <a href="findbugsResult/HIGH">priority High</a> exceed the threshold of 0 by 5
          but the build just proceeds as if the report would not find anything.
          Within a pipeline, I have configured findbugs report :

          {{deleteDir()}}
          {{ checkout scm}}
          {{ sh "mvn clean install"}}{{findbugs defaultEncoding: '', excludePattern: '', healthy: '', includePattern: '', pattern: '**/findbugsXml.xml', failedTotalHigh: '0', unHealthy: ''}}

          The report is produced correctly. But if a 'High' issue appears, the build is not aborted, and not set to status 'failed'.

          In the console log, findbugs reports:


          {{ [FINDBUGS] Plug-in Result: Failed - <a href="findbugsResult">5 warnings</a> of <a href="findbugsResult/HIGH">priority High</a> exceed the threshold of 0 by 5}}


           but the build just proceeds as if the report would not find anything.
          tobias_hd Tobias Munk made changes -
          Description Within a pipeline, I have configured findbugs report :

          {{deleteDir()}}
          {{ checkout scm}}
          {{ sh "mvn clean install"}}{{findbugs defaultEncoding: '', excludePattern: '', healthy: '', includePattern: '', pattern: '**/findbugsXml.xml', failedTotalHigh: '0', unHealthy: ''}}

          The report is produced correctly. But if a 'High' issue appears, the build is not aborted, and not set to status 'failed'.

          In the console log, findbugs reports:


          {{ [FINDBUGS] Plug-in Result: Failed - <a href="findbugsResult">5 warnings</a> of <a href="findbugsResult/HIGH">priority High</a> exceed the threshold of 0 by 5}}


           but the build just proceeds as if the report would not find anything.
          Within a pipeline, I have configured findbugs report :
          {quote}{{deleteDir()}}
           checkout scm
           sh "mvn clean install"

          {{findbugs defaultEncoding: '', excludePattern: '', healthy: '', includePattern: '', pattern: '**/findbugsXml.xml', failedTotalHigh: '0', unHealthy: ''}}
          {quote}
          The report is produced correctly. But if a 'High' issue appears, the build is not aborted, and not set to status 'failed'.

          In the console log, findbugs reports:
          {quote}[FINDBUGS] Plug-in Result: Failed - <a href="findbugsResult">5 warnings</a> of <a href="findbugsResult/HIGH">priority High</a> exceed the threshold of 0 by 5
          {quote}
          but the build just proceeds as if the report would not find anything.
          drulli Ulli Hafner made changes -
          Comment [ I created a test case in ATH to reproduce the bug without success. The test cases verifies three different thresholds for unstable or failure but all work as expected. Is there anything different in your setup? ]
          drulli Ulli Hafner made changes -
          Status Open [ 1 ] Resolved [ 5 ]
          Resolution Cannot Reproduce [ 5 ]

            People

            • Assignee:
              drulli Ulli Hafner
              Reporter:
              tobias_hd Tobias Munk
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: