Skip to content

[JENKINS-28113] BuildTrigger should accept any ParameterizedJob downstream #21070

Closed

Description

@jenkins-infra-bot

ReverseBuildTrigger supports any ParameterizedJob, behaving as a DependencyDeclarer if both sides are AbstractProject, behaving as a simple Trigger otherwise. BuildTrigger should do the same, behaving as a DependencyDeclarer as now if both sides are AbstractProject, behaving as a simple Notifier otherwise.

Would allow Build other projects to select a workflow job. Workarounds: JENKINS-26050, if implemented; use of ReverseBuildTrigger, in the common case that it does not matter which side declares the trigger (but not when Item.CONFIGURE is restricted on one side, job templates are in use, etc.).


Originally reported by jglick, imported from: BuildTrigger should accept any ParameterizedJob downstream
  • assignee: jglick
  • status: Resolved
  • priority: Minor
  • component(s): core
  • label(s): pipeline
  • resolution: Fixed
  • resolved: 2017-05-14T19:24:50+00:00
  • votes: 0
  • watchers: 2
  • imported: 2025-11-24
Raw content of original issue

ReverseBuildTrigger supports any ParameterizedJob, behaving as a DependencyDeclarer if both sides are AbstractProject, behaving as a simple Trigger otherwise. BuildTrigger should do the same, behaving as a DependencyDeclarer as now if both sides are AbstractProject, behaving as a simple Notifier otherwise.

Would allow Build other projects to select a workflow job. Workarounds: JENKINS-26050, if implemented; use of ReverseBuildTrigger, in the common case that it does not matter which side declares the trigger (but not when Item.CONFIGURE is restricted on one side, job templates are in use, etc.).

Activity

  1. jenkins-infra-bot commented on Apr 27, 2015

    @jenkins-infra-bot
    Author
  2. jenkins-infra-bot commented on May 14, 2017

    @jenkins-infra-bot
    Author
    scm_issue_link:
    • Original comment link
    • Raw content of original comment:

      Code changed in jenkins User: Jesse Glick Path: core/src/main/java/hudson/model/AbstractProject.java core/src/main/java/hudson/tasks/BuildTrigger.java http://jenkins-ci.org/commit/jenkins/f1a26582c1b25c470989d19b25378cff5c6d2497 Log: JENKINS-28113 Allow freestyle builds to trigger downstream Pipeline builds (#2873)

      • Offering default methods on ParameterizedJob.
      • Javadoc typo.
      • Cleaner use of default methods in ParameterizedJob.
      • Sketch of pulling disabled functionality into ParameterizedJob.
      • EnableJobCommandTest.groovy → EnableJobCommandTest.java, and replacing deprecated Remoting-based CLI calls with CLICommandInvoker.
      • All CLI commands could be broken by a missing CLI.*.shortDescription key on just one!
      • Forgot to move CLI method short descriptions to new package.
      • Needed a @CLIResolver for ParameterizedJob. Adding an OptionHandler while we are here.
      • Trying to fix up access-modifier versions; started failing in CI today for unknown reasons.
      • Introduced <p:makeDisabled/> by analogy with <p:config-disableBuild/>.
      • Using new type bounds.
      • access-modifier 1.11 released.
      • MatrixProject and MavenModuleSet both expect to have access to makeDisabled.jelly.
      • Trying to generalize some more.
      • Minor simplification.
      • isBuildable
      • Obsolete comment.
      • Updated comments.
      • bridge-method-injector 1.17
      • Unfortunately AbstractProject.schedulePolling cannot delegate to SCMTriggerItem.
      • [FIXED JENKINS-28113] Generalize BuildTrigger to be able to trigger non-AbstractProject downstream ParameterizedJob’s without DependencyGraph.
      • JENKINS-22949 Dropping QueueItemAuthenticator trickiness, as in #2881.

    Code changed in jenkins
    User: Jesse Glick
    Path:
    core/src/main/java/hudson/model/AbstractProject.java
    core/src/main/java/hudson/tasks/BuildTrigger.java
    http://jenkins-ci.org/commit/jenkins/f1a26582c1b25c470989d19b25378cff5c6d2497
    Log:
    JENKINS-28113 Allow freestyle builds to trigger downstream Pipeline builds (#2873)

    • Offering default methods on ParameterizedJob.
    • Javadoc typo.
    • Cleaner use of default methods in ParameterizedJob.
    • Sketch of pulling disabled functionality into ParameterizedJob.
    • EnableJobCommandTest.groovy → EnableJobCommandTest.java, and replacing deprecated Remoting-based CLI calls with CLICommandInvoker.
    • All CLI commands could be broken by a missing CLI.*.shortDescription key on just one!
    • Forgot to move CLI method short descriptions to new package.
    • Needed a @​CLIResolver for ParameterizedJob. Adding an OptionHandler while we are here.
    • Trying to fix up access-modifier versions; started failing in CI today for unknown reasons.
    • Introduced by analogy with .
    • Using new type bounds.
    • access-modifier 1.11 released.
    • MatrixProject and MavenModuleSet both expect to have access to makeDisabled.jelly.
    • Trying to generalize some more.
    • Minor simplification.
    • isBuildable
    • Obsolete comment.
    • Updated comments.
    • bridge-method-injector 1.17
    • Unfortunately AbstractProject.schedulePolling cannot delegate to SCMTriggerItem.
    • [FIXED JENKINS-28113] Generalize BuildTrigger to be able to trigger non-AbstractProject downstream ParameterizedJob’s without DependencyGraph.
  3. jenkins-infra-bot commented on May 14, 2017

    @jenkins-infra-bot
    Author
    danielbeck:
    • Original comment link
    • Raw content of original comment:

      Fixed towards 2.61.

    Fixed towards 2.61.

  4. jenkins-infra-bot commented on May 17, 2017

    @jenkins-infra-bot
    Author
    scm_issue_link:

    Code changed in jenkins
    User: Jesse Glick
    Path:
    pom.xml
    src/test/java/org/jenkinsci/plugins/workflow/job/BuildTriggerTest.java
    src/test/java/org/jenkinsci/plugins/workflow/job/ReverseBuildTriggerTest.java
    http://jenkins-ci.org/commit/workflow-job-plugin/f4e8795cd27578cdf904c91b187e5b8975584d80
    Log:
    JENKINS-28113 Integration test of BuildTrigger with WorkflowJob downstream.

  5. jenkins-infra-bot commented on May 17, 2017

    @jenkins-infra-bot
    Author
    scm_issue_link:

    Code changed in jenkins
    User: Jesse Glick
    Path:
    src/test/java/org/jenkinsci/plugins/workflow/job/BuildTriggerTest.java
    src/test/java/org/jenkinsci/plugins/workflow/job/ReverseBuildTriggerTest.java
    http://jenkins-ci.org/commit/workflow-job-plugin/33944ba447655c594796a294bce379041ea48f5f
    Log:
    Merge pull request #48 from jglick/BuildTrigger-ParameterizedJob-JENKINS-28113

    JENKINS-28113 BuildTrigger integration test

    Compare: jenkinsci/workflow-job-plugin@8da02e9...33944ba

  6. jenkins-infra-bot commented on Nov 24, 2025

    @jenkins-infra-bot
    Author

    [Original relates_to from Jira: JENKINS-28071]

  7. jenkins-infra-bot commented on Nov 24, 2025

    @jenkins-infra-bot
    Author

    [Original relates_to from Jira: JENKINS-26050]

  8. jenkins-infra-bot commented on Nov 24, 2025

    @jenkins-infra-bot
    Author

    [Original relates_to from Jira: JENKINS-29913]

  9. jenkins-infra-bot commented on Nov 24, 2025

    @jenkins-infra-bot
    Author

    [Original relates_to from Jira: JENKINS-32525]

  10. removed
    bugFor changelog: Minor bug. Will be listed after features
    on Nov 25, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions