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

ReverseBuildTrigger.threshold not consistently saved

      Created three jobs: job A, job B, job C. Set job B config to be triggered after job A and to trigger job C. In this case, radio button in the section "build after other projects are built" cannot be saved (even if you save and reopen the configuration page). When job A is built, a NullPointerException is thrown and job B is not started (see attachments). If you chain only job B to job A, it works.

          [JENKINS-23191] ReverseBuildTrigger.threshold not consistently saved

          It seems there is still a problem, don't know whether it is the same: Previously the "build after other project"-trigger was a mirror of the post-build-action "Build other project". Now, you can alter the "Build other project" (e.g. removing job C from PBA of job B) and the trigger in job C is not updated. On the other hand changes in trigger of job C are not reflected in job B anymore. Actually the settings in job C have no effect, ie. when no PBA is configured in B, job C is never triggered, whatever it's configuration is.

          Christian Langmann added a comment - It seems there is still a problem, don't know whether it is the same: Previously the "build after other project"-trigger was a mirror of the post-build-action "Build other project". Now, you can alter the "Build other project" (e.g. removing job C from PBA of job B) and the trigger in job C is not updated. On the other hand changes in trigger of job C are not reflected in job B anymore. Actually the settings in job C have no effect, ie. when no PBA is configured in B, job C is never triggered, whatever it's configuration is.

          Daniel Beck added a comment - - edited

          Christian: This is a deliberate, documented change. Quoting the changelog for 1.560:

          The “upstream pseudo trigger” was also removed in favor of a true trigger configured on the downstream project; you may use either the post-build action or the trigger according to where you want this configuration stored, and who is authorized to change it.


          Actually the settings in job C have no effect, ie. when no PBA is configured in B, job C is never triggered, whatever it's configuration is.

          This could be a legitimate bug. Could you provide complete and detailed steps to reproduce this on a test instance with default plugins?

          Daniel Beck added a comment - - edited Christian: This is a deliberate, documented change. Quoting the changelog for 1.560: The “upstream pseudo trigger” was also removed in favor of a true trigger configured on the downstream project; you may use either the post-build action or the trigger according to where you want this configuration stored, and who is authorized to change it. Actually the settings in job C have no effect, ie. when no PBA is configured in B, job C is never triggered, whatever it's configuration is. This could be a legitimate bug. Could you provide complete and detailed steps to reproduce this on a test instance with default plugins?

          Seems to be a problem of the Maven-job:

          Setup "job A" as Freestyle Project
          Setup "job B" as Freestyle Project and set "job A" as trigger (Status shows job A as Upstream Project)

          Setup "job Maven-B" as Maven Project and set "job A" as trigger (Status does not show any upstream project)

          When "job A" is build and finishes, "job B" is triggered, but not "job Maven-B"

          You can make "job Maven-B" triggered by "job A" by setting it as a Post-Build-Action in "job A"

          Christian Langmann added a comment - Seems to be a problem of the Maven-job: Setup "job A" as Freestyle Project Setup "job B" as Freestyle Project and set "job A" as trigger (Status shows job A as Upstream Project) Setup "job Maven-B" as Maven Project and set "job A" as trigger (Status does not show any upstream project) When "job A" is build and finishes, "job B" is triggered, but not "job Maven-B" You can make "job Maven-B" triggered by "job A" by setting it as a Post-Build-Action in "job A"

          Daniel Beck added a comment -

          Christian: Does this only affect Maven projects?

          Daniel Beck added a comment - Christian: Does this only affect Maven projects?

          Daniel: At least Freestyle doesn't have this problem

          Christian Langmann added a comment - Daniel: At least Freestyle doesn't have this problem

          Daniel Beck added a comment -

          Christian: Please file a new bug for the 'maven' and 'core' components with this description. Link it to this one as related (More Actions button).

          Daniel Beck added a comment - Christian: Please file a new bug for the 'maven' and 'core' components with this description. Link it to this one as related (More Actions button).

          Code changed in jenkins
          User: Jesse Glick
          Path:
          test/src/test/java/jenkins/triggers/ReverseBuildTriggerTest.java
          http://jenkins-ci.org/commit/jenkins/84195ea8468766df8df470f3a1a686caefb644a3
          Log:
          JENKINS-23191 Cannot reproduce problem in HtmlUnit test, but can at least guard against other regressions.
          (cherry picked from commit e1e7f1b93b48998e1068275c6406335e7b7f364d)

          SCM/JIRA link daemon added a comment - Code changed in jenkins User: Jesse Glick Path: test/src/test/java/jenkins/triggers/ReverseBuildTriggerTest.java http://jenkins-ci.org/commit/jenkins/84195ea8468766df8df470f3a1a686caefb644a3 Log: JENKINS-23191 Cannot reproduce problem in HtmlUnit test, but can at least guard against other regressions. (cherry picked from commit e1e7f1b93b48998e1068275c6406335e7b7f364d)

          Code changed in jenkins
          User: Jesse Glick
          Path:
          core/src/main/resources/hudson/tasks/BuildTrigger/config.jelly
          core/src/main/resources/jenkins/triggers/ReverseBuildTrigger/config.jelly
          core/src/main/resources/lib/form/radio.jelly
          http://jenkins-ci.org/commit/jenkins/bd378a1ed2472dabab979ae727cb54459e098431
          Log:
          [FIXED JENKINS-23191] f:radio is not databinding-aware and does not correctly handle multiple configuration sections unless you make it.
          (cherry picked from commit d660d60ea7e2e411972b215fc7f6fee9ff03e329)

          Conflicts:
          changelog.html

          SCM/JIRA link daemon added a comment - Code changed in jenkins User: Jesse Glick Path: core/src/main/resources/hudson/tasks/BuildTrigger/config.jelly core/src/main/resources/jenkins/triggers/ReverseBuildTrigger/config.jelly core/src/main/resources/lib/form/radio.jelly http://jenkins-ci.org/commit/jenkins/bd378a1ed2472dabab979ae727cb54459e098431 Log: [FIXED JENKINS-23191] f:radio is not databinding-aware and does not correctly handle multiple configuration sections unless you make it. (cherry picked from commit d660d60ea7e2e411972b215fc7f6fee9ff03e329) Conflicts: changelog.html

          Jesse Glick added a comment -

          @christianlangmann file in maven component and link to JENKINS-16956 (probably not directly related to this bug).

          Jesse Glick added a comment - @christianlangmann file in maven component and link to JENKINS-16956 (probably not directly related to this bug).

          @Jesse, @Daniel: Thanks for advice, bug created: JENKINS-23686

          Christian Langmann added a comment - @Jesse, @Daniel: Thanks for advice, bug created: JENKINS-23686

            jglick Jesse Glick
            donato73 Donato Tagliabue
            Votes:
            1 Vote for this issue
            Watchers:
            7 Start watching this issue

              Created:
              Updated:
              Resolved: