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

Add support for multi-module maven jobs when comparing successful build results

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Component/s: analysis-core-plugin
    • Labels:
      None
    • Environment:
      Platform: All, OS: All

      Description

      I've setup the plugin to fail the build when >=10 new FindBugs issues are detected.
      I've got normally around 20 unresolved warnings in my Maven multimodule project.
      Now the following can happen:

      • build n fails because of compilation error => warnings go down to < 10
      • build n+1 compile again, but is set to failed by FindBugs plugin, because it
        thinks there are more then 10 new warnings

      My suggestion: the plugin should compare the number of 'new' warnings against
      the last successful build. And probably skip the 'new' check altogether if it
      cannot find a previous successful build.

        Issue Links

          Activity

          Hide
          kutzi kutzi added a comment -

          If this would help to fix this more quickly and you could point me to where I
          can find this in the plugin's sources, I could have a look to prepare a patch
          for this.

          Show
          kutzi kutzi added a comment - If this would help to fix this more quickly and you could point me to where I can find this in the plugin's sources, I could have a look to prepare a patch for this.
          Hide
          drulli Ulli Hafner added a comment -

          Hmm, this seems to be a bug.

          The new threshold is computed by:
          "warnings of the current build" - "warning from last build with a findbugs result"

          If the build fails then the findbugs plug-in should be skipped. Which kind of
          build are you using? Is there a findbugs.xml computed for failed builds?

          BTW: for the source code see
          http://wiki.jenkins-ci.org/display/JENKINS/Extend+Hudson.

          Show
          drulli Ulli Hafner added a comment - Hmm, this seems to be a bug. The new threshold is computed by: "warnings of the current build" - "warning from last build with a findbugs result" If the build fails then the findbugs plug-in should be skipped. Which kind of build are you using? Is there a findbugs.xml computed for failed builds? BTW: for the source code see http://wiki.jenkins-ci.org/display/JENKINS/Extend+Hudson .
          Hide
          kutzi kutzi added a comment -

          > Which kind of build are you using?

          Maven 2 project type with a Maven multimodule project

          > Is there a findbugs.xml computed for failed builds?

          I suppose so as only some child modules failed and not all.
          And since the Hudson project overview displays 4 warnings for that build.
          I don't know though, how to find the workspace for old builds.

          Show
          kutzi kutzi added a comment - > Which kind of build are you using? Maven 2 project type with a Maven multimodule project > Is there a findbugs.xml computed for failed builds? I suppose so as only some child modules failed and not all. And since the Hudson project overview displays 4 warnings for that build. I don't know though, how to find the workspace for old builds.
          Hide
          drulli Ulli Hafner added a comment -

          I see, for multi-module maven jobs the decision is not that easy

          I'll check if there is a way in my plug-in to decide which of the modules is the root
          module. Then the old and simple algorithm will still work if applied only to this root
          module.

          Show
          drulli Ulli Hafner added a comment - I see, for multi-module maven jobs the decision is not that easy I'll check if there is a way in my plug-in to decide which of the modules is the root module. Then the old and simple algorithm will still work if applied only to this root module.
          Hide
          kutzi kutzi added a comment -
              • Issue 4645 has been marked as a duplicate of this issue. ***
          Show
          kutzi kutzi added a comment - Issue 4645 has been marked as a duplicate of this issue. ***
          Hide
          drulli Ulli Hafner added a comment -

          Hopefully, this is also fixed with the complete rework of the m2 integration (see JENKINS-4912).

          Show
          drulli Ulli Hafner added a comment - Hopefully, this is also fixed with the complete rework of the m2 integration (see JENKINS-4912 ).

            People

            • Assignee:
              drulli Ulli Hafner
              Reporter:
              kutzi kutzi
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: