• 5.0.0-beta2

      jI have different findbugs goals in my pom file configured.

      One is executed as check to break the build instantly if some rules are violated.
      The second one is the normal findbugs goal.

      I have noticed that only the first one is tracked.

          [JENKINS-31633] Only first execution is tracked

          C. S. created issue -

          Ulli Hafner added a comment -

          Are you using a maven job? Here the first findbugs goal is picked up.

          Workaround: use the freestyle project.

          Ulli Hafner added a comment - Are you using a maven job? Here the first findbugs goal is picked up. Workaround: use the freestyle project.

          C. S. added a comment -

          Yes I am using a maven job and we need the possibilities of it.

          Is there no way to fetch more than one goal or just take the result of a findbugs goal instead of check?

          C. S. added a comment - Yes I am using a maven job and we need the possibilities of it. Is there no way to fetch more than one goal or just take the result of a findbugs goal instead of check?

          Ulli Hafner added a comment - - edited

          No, currently it runs for the first goal that has the text findbugs in it. Maybe you can change your check configuration to something like in JENKINS-29414?

          Ulli Hafner added a comment - - edited No, currently it runs for the first goal that has the text findbugs in it. Maybe you can change your check configuration to something like in JENKINS-29414 ?

          C. S. added a comment - - edited

          I don't see the difference, but my plan as workaround will be to change the execution order of the jenkins profile. It should execute the findbugs goal at first and after it the check goal.

          C. S. added a comment - - edited I don't see the difference, but my plan as workaround will be to change the execution order of the jenkins profile. It should execute the findbugs goal at first and after it the check goal.

          C. S. added a comment -

          It seems not as easy as thought to change the order of the excection caused by the check goal design.

          The check goal calls internally the findbugs/pmd report goal and detects if there is already a report file and takes it instead of reanalysis.

          Is there any possibility to skip check goals in your plugin?

          C. S. added a comment - It seems not as easy as thought to change the order of the excection caused by the check goal design. The check goal calls internally the findbugs/pmd report goal and detects if there is already a report file and takes it instead of reanalysis. Is there any possibility to skip check goals in your plugin?

          Ulli Hafner added a comment -

          From the source code I see that only the goal findbugs or site should match:
          https://github.com/jenkinsci/findbugs-plugin/blob/master/plugin/src/main/java/hudson/plugins/findbugs/FindBugsReporter.java#L199

          What exactly are your maven goals?

          Ulli Hafner added a comment - From the source code I see that only the goal findbugs or site should match: https://github.com/jenkinsci/findbugs-plugin/blob/master/plugin/src/main/java/hudson/plugins/findbugs/FindBugsReporter.java#L199 What exactly are your maven goals?

          C. S. added a comment -

          Yes you are right it should cover my goals. But the second time it isn't executed.

          Here the jenkins output:

          [INFO] --- findbugs-maven-plugin:3.0.3:findbugs (findbugs) @ business ---
          [INFO] Fork Value is true
          [INFO] Done FindBugs Analysis....
          [FINDBUGS] Finding all files that match the pattern findbugsXml.xml
          [FINDBUGS] Parsing 1 file in TRUNK/business/target
          [FINDBUGS] Successfully parsed file TRUNK/business/target/findbugsXml.xml of module Heatsoak Business with 0 unique warnings and 0 duplicates.
          [FINDBUGS] Computing warning deltas based on reference build #1029
          [INFO] 
          [INFO] <<< findbugs-maven-plugin:3.0.3:check (findbugs-always) < :findbugs @ business <<<
          [INFO] 
          [INFO] --- findbugs-maven-plugin:3.0.3:check (findbugs-always) @ business ---
          [INFO] BugInstance size is 0
          [INFO] Error size is 0
          [INFO] No errors/warnings found
          ...
          [INFO] --- findbugs-maven-plugin:3.0.3:findbugs (findbugs-normal) @ business ---
          [INFO] Fork Value is true
               [java] Warnings generated: 47
          [INFO] Done FindBugs Analysis....
          

          C. S. added a comment - Yes you are right it should cover my goals. But the second time it isn't executed. Here the jenkins output: [INFO] --- findbugs-maven-plugin:3.0.3:findbugs (findbugs) @ business --- [INFO] Fork Value is true [INFO] Done FindBugs Analysis.... [FINDBUGS] Finding all files that match the pattern findbugsXml.xml [FINDBUGS] Parsing 1 file in TRUNK/business/target [FINDBUGS] Successfully parsed file TRUNK/business/target/findbugsXml.xml of module Heatsoak Business with 0 unique warnings and 0 duplicates. [FINDBUGS] Computing warning deltas based on reference build #1029 [INFO] [INFO] <<< findbugs-maven-plugin:3.0.3:check (findbugs-always) < :findbugs @ business <<< [INFO] [INFO] --- findbugs-maven-plugin:3.0.3:check (findbugs-always) @ business --- [INFO] BugInstance size is 0 [INFO] Error size is 0 [INFO] No errors/warnings found ... [INFO] --- findbugs-maven-plugin:3.0.3:findbugs (findbugs-normal) @ business --- [INFO] Fork Value is true [java] Warnings generated: 47 [INFO] Done FindBugs Analysis....

          Ulli Hafner added a comment -

          Ah, but the first goal is also called 'findbugs'! I thought the first goal is called 'check'? Seems that your check goal already starts the 'findbugs' goal internally! Then it will not work: the plug-in always uses the result of the first invokation of the 'findbugs' goal.

          Ulli Hafner added a comment - Ah, but the first goal is also called 'findbugs'! I thought the first goal is called 'check'? Seems that your check goal already starts the 'findbugs' goal internally! Then it will not work: the plug-in always uses the result of the first invokation of the 'findbugs' goal.

          C. S. added a comment -

          I have copied too less output. Before the first findbugs there is the check goal. And yes internally findbugs is called by check.

          Is there no way to instruct the plugin to use more than one file for the result?

          C. S. added a comment - I have copied too less output. Before the first findbugs there is the check goal. And yes internally findbugs is called by check. Is there no way to instruct the plugin to use more than one file for the result?

            drulli Ulli Hafner
            cschulz C. S.
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: