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

Avoid excessive triggering of downstream jobs

XMLWordPrintable

      JENKINS-44721 added the ability to trigger pipelines according to their SNAPSHOT dependencies. This can lead to the problem that sometimes many builds are triggered. JENKINS-46152 avoids this by introducing a flag to disable triggering altogether, but then the benefit of the triggers is lost.

      The old Maven project type had a feature called "Block downstream trigger when building" which would be helpful in this situation. That feature doesn't skip all the downstream triggers, but only the triggers of those downstream dependencies which will later on be triggered by other downstream dependencies.

      To explain it with an example: imagine Maven projects A, B, and C, where B depends on A, and C depends on both A and B. Currently, when A is built, C gets triggered twice, once by A and once by B (which is also triggered by A). But with the proposed feature, C only gets triggered by B, because A knows that B will trigger C later on and will therefore skip that trigger.

      Of course, this feature should be introduced with a new flag to preserve the current behavior.

            cleclerc Cyrille Le Clerc
            markusdlugi Markus Dlugi
            Votes:
            6 Vote for this issue
            Watchers:
            11 Start watching this issue

              Created:
              Updated:
              Resolved: