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

Deploy all built modules on success, including from previous failed builds

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • maven-plugin
    • None
    • Version 1.329

      Setup

      Incremental build for a maven2 multi module project (module A, B and C). Target is "clean install" and "Deploy artifacts to Maven repository" is checked.

      Scenario

      1. Modules A and B are changed of which the change in module A causes a test to fail in that module.
      2. The build fails as unstable after both module A and B are built, and no module is deployed even if module B built ok. Fair.
      3. A fix is submitted for the failing test in module A.
      4. The fixed module A is rebuilt including the dependant module C and all is successfull again. Ok.
      5. Modules A and C are deployed to the repository, but not B! Not ok!

      Module B should also be deployed once the project is successfully built again. It's not ok to have to go to Hudson and manually force module B to be (re-) deployed.

      This is related to JENKINS-4152 in some sense, but specific for the deploy step after the build.

          [JENKINS-5121] Deploy all built modules on success, including from previous failed builds

          Jonas Bergvall created issue -
          Jonas Bergvall made changes -
          Environment New: Version 1.329
          Issue Type Original: Improvement [ 4 ] New: Bug [ 1 ]
          kutzi made changes -
          Link New: This issue is duplicated by JENKINS-5639 [ JENKINS-5639 ]
          kutzi made changes -
          Link New: This issue is related to JENKINS-5764 [ JENKINS-5764 ]

          kutzi added a comment -

          As written in JENKINS-5764, the best solution is possibly to rebuild (and thereby redeploy) all modules of a previous failing/unstable build.

          kutzi added a comment - As written in JENKINS-5764 , the best solution is possibly to rebuild (and thereby redeploy) all modules of a previous failing/unstable build.
          kutzi made changes -
          Assignee New: kutzi [ kutzi ]
          kutzi made changes -
          Link New: This issue is related to JENKINS-4152 [ JENKINS-4152 ]

          kutzi added a comment -

          Thought about the previous comment and I think we cannot simply do it.
          Some people might be used to some builds being unstable all the time (yes that wouldn't be a sane CI usage IMO, but nevertheless possible) and still want to do incremental builds.

          What I can do instead, is to check if "Deploy artifacts to Maven repository" is checked and only in that case rebuild the modules next time.

          kutzi added a comment - Thought about the previous comment and I think we cannot simply do it. Some people might be used to some builds being unstable all the time (yes that wouldn't be a sane CI usage IMO, but nevertheless possible) and still want to do incremental builds. What I can do instead, is to check if "Deploy artifacts to Maven repository" is checked and only in that case rebuild the modules next time.

          Code changed in jenkins
          User: Christoph Kutzinski
          Path:
          maven-plugin/src/main/java/hudson/maven/MavenBuild.java
          maven-plugin/src/main/java/hudson/maven/MavenModuleSetBuild.java
          test/src/test/java/hudson/maven/MavenMultiModuleTest.java
          http://jenkins-ci.org/commit/jenkins/e499283310a473df6753da88af9f548ecb4a34c8
          Log:
          [FIXED JENKINS-5121] for incremental builds with "Deploy artifacts" checked, all modules must be build again after an unsuccessful aggregator build

          SCM/JIRA link daemon added a comment - Code changed in jenkins User: Christoph Kutzinski Path: maven-plugin/src/main/java/hudson/maven/MavenBuild.java maven-plugin/src/main/java/hudson/maven/MavenModuleSetBuild.java test/src/test/java/hudson/maven/MavenMultiModuleTest.java http://jenkins-ci.org/commit/jenkins/e499283310a473df6753da88af9f548ecb4a34c8 Log: [FIXED JENKINS-5121] for incremental builds with "Deploy artifacts" checked, all modules must be build again after an unsuccessful aggregator build
          SCM/JIRA link daemon made changes -
          Resolution New: Fixed [ 1 ]
          Status Original: Open [ 1 ] New: Resolved [ 5 ]

            kutzi kutzi
            jonbe242 Jonas Bergvall
            Votes:
            1 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved: