Details

Description

I have a repository which is setup to perform git polling, and it always triggers, suggesting there are changes, even though there are not.

In this case, the job has multiple checkouts using a pipeline, but I think it would only happen in the case of a single checkout as well.

Specifically, the branch name is master, and it checks first all the "remote/branch" combinations, (in this case, "origin/master") and then fails to find anything new (as origin/master was already built). Then, it checks the branch name on its own, thinking that maybe it's a tag or some other ref.

This results in reporting a separate commit (likely whatever master happens to be at when the polling was created), and thus reports a new commit to build. This causes the build to trigger every polling timeout, even though there aren't any real new changes.

Here's a subset of the actual output with repository names and paths redacted. I have the VERBOSE logging enabled for more information.

I believe what is happening is that the "remote/branch" output is failing to find any new changes, so we fall back to attempting to resolve the name like a tag, but it so happens that the polling setup actually does end up with the branch checked out, and it results in us finding the local master name and reporting it.

I don't really know how to resolve this yet.

Attachments

Issue Links

relates to

JENKINS-50401Checkout resolution misbehaves with local branch and forward slashes

Fixed but Unreleased

Activity

Jacob, thanks for the info... it turns out that I did in fact have the "author in change log" option selected, and that was why workspace polling was being used. By disabling that option, the plugin started doing remote polling.

Phil Adams
added a comment - 2018-04-24 16:35 Jacob, thanks for the info... it turns out that I did in fact have the "author in change log" option selected, and that was why workspace polling was being used. By disabling that option, the plugin started doing remote polling.

I submitted a pull request https://github.com/jenkinsci/git-plugin/pull/583 which should remove that restriction (as far as I can tell, it was inadvertently added and there's no reason that the extension "author in change log" depends on the workspace polling.

Jacob Keller
added a comment - 2018-04-24 17:03 I submitted a pull request https://github.com/jenkinsci/git-plugin/pull/583 which should remove that restriction (as far as I can tell, it was inadvertently added and there's no reason that the extension "author in change log" depends on the workspace polling.

I've been evaluating this pull request today. Evaluation is not complete, but it is looking good. I'd like to include this in the 4.0.0-beta1 release. However, I first need to merge several other changes (the require-jdk-8 PR and a few others that I've already evaluated).

I need some help Raul Arabaolaza to understand the test failures on the pull request. I'll connect with him early next week for further discussion.

Mark Waite
added a comment - 2018-05-13 03:00 I've been evaluating this pull request today. Evaluation is not complete, but it is looking good. I'd like to include this in the 4.0.0-beta1 release. However, I first need to merge several other changes (the require-jdk-8 PR and a few others that I've already evaluated).
I need some help Raul Arabaolaza to understand the test failures on the pull request. I'll connect with him early next week for further discussion.

I've had this pull request running as well in my test instance that I setup to test the thousands of branches case with the build details pull request as well, so far I haven't found any issues either.

I'm curious what the ATH thing is as well. Hopefully we can get to the bottom of that one.

Jacob Keller
added a comment - 2018-05-13 20:22 I've had this pull request running as well in my test instance that I setup to test the thousands of branches case with the build details pull request as well, so far I haven't found any issues either.
I'm curious what the ATH thing is as well. Hopefully we can get to the bottom of that one.