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

Build status should not be limited to SUCCESS for downstream triggering

    XMLWordPrintable

    Details

    • Similar Issues:

      Description

      getTriggerDownstreamBuildsCriteria() is hardcoded and we can't configure the criteria.

      I would at least need UNSTABLE.

        Attachments

          Activity

          Hide
          cleclerc Cyrille Le Clerc added a comment -
          Show
          cleclerc Cyrille Le Clerc added a comment - Reference  https://github.com/jenkinsci/pipeline-maven-plugin/blob/pipeline-maven-3.0.0/jenkins-plugin/src/main/java/org/jenkinsci/plugins/pipeline/maven/listeners/DownstreamPipelineTriggerRunListener.java#L58 Note: it's for the moment a global configuration flag. It cannot easily be refined at the pipeline level  
          Hide
          pino Pino Silvaggio added a comment -

          Yes, I understand. In fact, I forked the plugin and changed the behavior for our needs.

          There is no way of configuring this, even globally, right?

          Show
          pino Pino Silvaggio added a comment - Yes, I understand. In fact, I forked the plugin and changed the behavior for our needs. There is no way of configuring this, even globally, right?
          Hide
          cleclerc Cyrille Le Clerc added a comment - - edited

          Pino Silvaggio few questions to understand your use case please:

          • How do you share the generated artifact with the downstream jobs?
            • Do you "mvn deploy"? Artifactory? Nexus? other?
            • Do you "mvn install"?
          • Why do you want to trigger downstream pipelines when a build is unstable? Because the artifact has been uploaded to a maven repository?
          • Would you like an option to say "trigger downstream pipelines that has a dependency on any generated artifact that has been uploaded to a maven repo, whatever the build status"?

          > There is no way of configuring this, even globally, right?

          Correct. The main reason is that it cannot be configured at the "withMaven(){}' level

          Show
          cleclerc Cyrille Le Clerc added a comment - - edited Pino Silvaggio few questions to understand your use case please: How do you share the generated artifact with the downstream jobs? Do you "mvn deploy"? Artifactory? Nexus? other? Do you "mvn install"? Why do you want to trigger downstream pipelines when a build is unstable? Because the artifact has been uploaded to a maven repository? Would you like an option to say "trigger downstream pipelines that has a dependency on any generated artifact that has been uploaded to a maven repo, whatever the build status"? > There is no way of configuring this, even globally, right? Correct. The main reason is that it cannot be configured at the "withMaven(){}' level
          Hide
          pino Pino Silvaggio added a comment -

          We have what we call "Flash Builds", which are builds triggered by GitLab Hooks. They build the project and execute unit tests, no IT. Even if they are unstable they should trigger downstream jobs so the final package can be used or tested for different scenarios. This is essential for us.

           

          We use mvn deploy yes. Artifactory, yes.

          Show
          pino Pino Silvaggio added a comment - We have what we call "Flash Builds", which are builds triggered by GitLab Hooks. They build the project and execute unit tests, no IT. Even if they are unstable they should trigger downstream jobs so the final package can be used or tested for different scenarios. This is essential for us.   We use mvn deploy yes. Artifactory, yes.
          Hide
          cleclerc Cyrille Le Clerc added a comment - - edited

          I forgot to take a screenshot. It's on the Global Tool Configuration Screen https://github.com/jenkinsci/pipeline-maven-plugin/pull/88

          Show
          cleclerc Cyrille Le Clerc added a comment - - edited I forgot to take a screenshot. It's on the Global Tool Configuration Screen  https://github.com/jenkinsci/pipeline-maven-plugin/pull/88
          Hide
          cleclerc Cyrille Le Clerc added a comment -

          merged

          Show
          cleclerc Cyrille Le Clerc added a comment - merged
          Show
          cleclerc Cyrille Le Clerc added a comment - Pino Silvaggio can you please test https://repo.jenkins-ci.org/releases/org/jenkins-ci/plugins/pipeline-maven/3.0.1-beta-1/pipeline-maven-3.0.1-beta-1.hpi?
          Hide
          cleclerc Cyrille Le Clerc added a comment -

          v.3.0.1

          Show
          cleclerc Cyrille Le Clerc added a comment - v.3.0.1

            People

            • Assignee:
              cleclerc Cyrille Le Clerc
              Reporter:
              pino Pino Silvaggio
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: