Hello,

I can't seem to understand my problem - setting poll: false in my Pipeline 
DSL doesn't alter the behavior of the Git Poll Log like I expect. I've ran 
the job multiple times, and I still see 2 polls within the logs when I 
expect there to only be one.

Workflow Job with an scm-polling trigger
Pipeline from SCM configured to do a sparse checkout and ignore commits 
from an automated user
Pipeline DSL operates within a docker container, with changelog and poll 
both set to false.

Using strategy: Default
[poll] Last Built Revision: Revision 57399c846b68250e81dff6f34feeb292664bdba5 
(origin/master)
 > git rev-parse --is-inside-work-tree # timeout=10
Fetching changes from the remote Git repositories
 > git config remote.origin.url [email protected]/kallan357/thing.git # timeout=10
Fetching upstream changes from [email protected]/kallan357/thing.git
 > git --version # timeout=10
using GIT_SSH to set credentials kallan357
 > git fetch --tags --progress [email protected]/kallan357/thing.git 
 > +refs/heads/*:refs/remotes/origin/*
Polling for changes in
 > git rev-parse origin/master^{commit} # timeout=10
 > git log --full-history --no-abbrev --format=raw -M -m --raw 
 > 57399c846b68250e81dff6f34feeb292664bdba5..31621a03c0eb1d58be8e8b0d0eebed6bae6ccb23
 >  # timeout=10
Ignored commit 31621a03c0eb1d58be8e8b0d0eebed6bae6ccb23: Found excluded author: 
jenkins-guy
Using strategy: Default
[poll] Last Built Revision: Revision 57399c846b68250e81dff6f34feeb292664bdba5 
(origin/master)
using GIT_SSH to set credentials kallan357
 > git --version # timeout=10
 > git ls-remote -h [email protected]/kallan357/thing.git # timeout=10
Found 45 remote heads on [email protected]/kallan357/thing.git
[poll] Latest remote head revision on refs/heads/master is: 
31621a03c0eb1d58be8e8b0d0eebed6bae6ccb23
Done. Took 0.43 sec
Changes found


Here is my DSL that lives inside SCM alongside my project:


node('java-docker-node') {
    timeout(15) {
        withEnv(envArray) {
            stage 'Checkout'
            git branch: 'master', credentialsId: 'abc123', changelog: false, 
poll: false, url: '[email protected]/kallan357/thing.git'

            stage 'Build'
            sh '''
            mvn clean install
            '''


            stage 'Bump versions'

            sh '''./bump_version.sh'''

        }

    }

}


My bump_version script will bump my pom and commit a new version to SCM. 
Because of the double sets of polling my job gets stuck in an infinite loop. 


Am I missing something? I've executed my build, which I suspect should modify 
the Jenkins polling behavior to only have a single attempt.


Thanks,

Kyle Allan

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/f2529515-78f1-4566-8ac0-52c5ca319841%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to