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

PollSCM triggers jobs even if there are no changes jenkinsfile declarative


       I'm using the github organization folder plugin to discover branches and pull requests dynamically. The discovery of new branches work as expected, but I want to reduce the time of discovering of new PR's and new commits for the specific repositories(by default is 1 day). For that I defined triggers { pollSCM('H/10 * * * *')} in the jenkinsfile(declarative) for some branches in some repos. I'm behind a firewall, so webhooks are not an option. However, the job triggers every 10 minutes in all the branches and PR's(until accepted) even if there are no changes after building once(it saves the trigger definition).

      According to the triggers documentation, it should run only if there are changes.

      I'm using this because GitSCM is not supported in the trigger definition. It would be super nice to have it in fact.


      Any ideas in how to deal with this would be great/

            Unassigned Unassigned
            clvx Luis Ibarra
            4 Vote for this issue
            6 Start watching this issue