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

Error 500 using Trigger parametrized build on other projects in Promotion process of a template

    XMLWordPrintable

    Details

    • Similar Issues:

      Description

      When adding a "Trigger parameterized build on other projects" or "Trigger/call build on other projects" step in the promotion process in a Job Template, the server raises a NullPointerException when processing the following request:

      For Trigger parameterized build on other projects:

      http://localhost:8083/job/test-template/descriptorByName/hudson.plugins.parameterizedtrigger.BuildTriggerConfig/checkProjects?value= 
      

      For Trigger/call build on other projects:

      http://localhost:8083/job/test-template/descriptorByName/hudson.plugins.parameterizedtrigger.BlockableBuildTriggerConfig/checkProjects?value=
      

      The method checkProjects in the BuildTriggerConfig assume that the @AncestorInPath is not null which is a bug.

      Source code here: https://github.com/jenkinsci/parameterized-trigger-plugin/blob/parameterized-trigger-2.29/src/main/java/hudson/plugins/parameterizedtrigger/BuildTriggerConfig.java#L602

      How to reproduce:

      • Create a Job Template "test-job" at the root
      • Tick "Define Promotion Process"
      • "Trigger parameterized build on other projects" action
      • An ERROR link appears
      • "Trigger/call build on other projects" action
      • An ERROR link appears

      Note: This issue does not block the functionality and this error can be ignored. Specifying an existing project and saving the configuration will make whis error disappears.

        Attachments

          Activity

          Hide
          allan_burdajewicz Allan BURDAJEWICZ added a comment - - edited
          Show
          allan_burdajewicz Allan BURDAJEWICZ added a comment - - edited Similar to JENKINS-32525 and JENKINS-32526
          Hide
          scm_issue_link SCM/JIRA link daemon added a comment -

          Code changed in jenkins
          User: Allan Burdajewicz
          Path:
          src/main/java/hudson/plugins/parameterizedtrigger/BuildTriggerConfig.java
          src/test/java/hudson/plugins/parameterizedtrigger/test/BuildTriggerConfigTest.java
          http://jenkins-ci.org/commit/parameterized-trigger-plugin/ffd67b5daa7cdcd1397b1de8ea471157d1ddbf53
          Log:
          JENKINS-32527 Handle null @AncestorInPath when selecting Downstream… (#98)

          • JENKINS-32527 Handle null @AncestorInPath when selecting Downstream Jobs
          Show
          scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Allan Burdajewicz Path: src/main/java/hudson/plugins/parameterizedtrigger/BuildTriggerConfig.java src/test/java/hudson/plugins/parameterizedtrigger/test/BuildTriggerConfigTest.java http://jenkins-ci.org/commit/parameterized-trigger-plugin/ffd67b5daa7cdcd1397b1de8ea471157d1ddbf53 Log: JENKINS-32527 Handle null @AncestorInPath when selecting Downstream… (#98) JENKINS-32527 Handle null @AncestorInPath when selecting Downstream Jobs JENKINS-32527 Resolved conflict
          Hide
          allan_burdajewicz Allan BURDAJEWICZ added a comment -

          Fixed in 2.34.

          Show
          allan_burdajewicz Allan BURDAJEWICZ added a comment - Fixed in 2.34.

            People

            • Assignee:
              allan_burdajewicz Allan BURDAJEWICZ
              Reporter:
              allan_burdajewicz Allan BURDAJEWICZ
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: