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

Poll SCM and Timer triggers include "Changes" for a Pipeline for any/all Shared Libraries

    Details

    • Similar Issues:
    • Sprint:
      Pipeline - July/August

      Description

      I noticed this while filing another ticket (JENKINS-41496), but the "Changes" view for the Pipeline run for this project "azure" has the "wrong commits" shown. See the screenshots for more.

      What basically appears to be happening is that any change to a Shared Library will result in newly triggered Pipelines which have "Poll SCM" configured. Pipelines which configure a timer will also have Changes from the Shared Library listed when it executes again.

      I think listing the Shared Library commits in "Changes" is acceptable, but triggering based on an SCM Poll for a Pipeline is very confusing behavior and IMHO incorrect behavior.

      As a shared tooling team, I would not expect my Shared Library changes to trigger a bunch of Pipelines for projects depending on them.

        Attachments

          Issue Links

            Activity

            Hide
            yrsurya suryatej yaramada added a comment -

            Even we are facing same issue , opened a ticket - https://issues.jenkins-ci.org/browse/JENKINS-52816

            Show
            yrsurya suryatej yaramada added a comment - Even we are facing same issue , opened a ticket -  https://issues.jenkins-ci.org/browse/JENKINS-52816
            Hide
            allan_burdajewicz Allan BURDAJEWICZ added a comment - - edited

            Is this still happening even after jobs are rebuilt at least once (see my comment above) ?

            If still hitting the problem, https://issues.jenkins-ci.org/browse/JENKINS-61415 (workflow-job:2.37) may help as it does not require a rebuild anymore. (nor a restart of Jenkins)

            Show
            allan_burdajewicz Allan BURDAJEWICZ added a comment - - edited Is this still happening even after jobs are rebuilt at least once (see my comment above) ? If still hitting the problem, https://issues.jenkins-ci.org/browse/JENKINS-61415 (workflow-job:2.37) may help as it does not require a rebuild anymore. (nor a restart of Jenkins)
            Hide
            dordor dor s added a comment - - edited

            in version 2.9 of workflow-cps-global-lib-plugin you added "allow excluding shared libraries from changelogs" as part of this commit https://github.com/jenkinsci/workflow-cps-global-lib-plugin/commit/64df779249ac69981a17f46e2698791fe95fa06d , but you never mentioned of how to do it in jenkins declarative pipeline?

            well, this is the syntax of loading shared library into the pipeline

            libraries {
              lib('some-library')
            }
            

            but I couldn't find any way to add the annotation of changelog=false in the jenkins declarative pipeline syntax. any idea how?

             

            some examples can be found here for jenkins scripted pipeline: https://stackoverflow.com/questions/46735908/jenkins-pipeline-global-pipeline-library-updates-show-up-in-jobs-list-of-rece
             

            Devin Nusbaum Tim Jacomb any chance that you can help here?

            Show
            dordor dor s added a comment - - edited in version 2.9 of  workflow-cps-global-lib-plugin  you added "allow excluding shared libraries from changelogs" as part of this commit https://github.com/jenkinsci/workflow-cps-global-lib-plugin/commit/64df779249ac69981a17f46e2698791fe95fa06d  , but you never mentioned of how to do it in jenkins declarative pipeline? well, this is the syntax of loading shared library into the pipeline libraries {   lib( 'some-library' ) } but I couldn't find any way to add the annotation of changelog=false in the jenkins declarative pipeline syntax. any idea how?   some examples can be found here for jenkins scripted pipeline: https://stackoverflow.com/questions/46735908/jenkins-pipeline-global-pipeline-library-updates-show-up-in-jobs-list-of-rece   Devin Nusbaum Tim Jacomb any chance that you can help here?
            Hide
            timja Tim Jacomb added a comment -

            You can configure it in the global config (which is what we do) no idea about in the pipeline

            Show
            timja Tim Jacomb added a comment - You can configure it in the global config (which is what we do) no idea about in the pipeline
            Hide
            dordor dor s added a comment -

            Hi Tim Jacomb , thank you for your reply. I forgot to mention it but I already tried to configure it in the global config but it's not affect on my declarative pipeline which located in github organization. So in case that there are new commits in the shared library git repo I see those changes as part of the pipeline which can be confusing or affect the change set array that I use to detect what files has been changed 

            Show
            dordor dor s added a comment - Hi Tim Jacomb , thank you for your reply. I forgot to mention it but I already tried to configure it in the global config but it's not affect on my declarative pipeline which located in github organization. So in case that there are new commits in the shared library git repo I see those changes as part of the pipeline which can be confusing or affect the change set array that I use to detect what files has been changed 

              People

              • Assignee:
                Unassigned
                Reporter:
                rtyler R. Tyler Croy
              • Votes:
                76 Vote for this issue
                Watchers:
                82 Start watching this issue

                Dates

                • Created:
                  Updated: