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

Pipeline job loop after polling always find changes

    Details

    • Similar Issues:

      Description

      Hi,

      We have a situation where my pipeline job is configured with branch "origin/develop"
      I have a master and a tests branches as well.

      Configured with polling every 5 minutes.

      There's no change in any of the branches and still polling 'detects' one on the system-tests branch...

      Polling Log example:

      Started on Nov 9, 2016 5:58:00 PM
      Using strategy: Default
      [poll] Last Built Revision: Revision 9b3f801b5ce8d6649c25ddd4a573801c9a6b5a23 (refs/remotes/origin/develop)
       > /usr/bin/git ls-remote -h ssh://my.git.server/git/test.git # timeout=10
      Found 3 remote heads on ssh://my.git.server/git/test.git
      [poll] Latest remote head revision on refs/heads/develop is: 9b3f801b5ce8d6649c25ddd4a573801c9a6b5a23 - already built by 4
      Using strategy: Default
      [poll] Last Built Revision: Revision 9b3f801b5ce8d6649c25ddd4a573801c9a6b5a23 (refs/remotes/origin/develop)
       > /usr/bin/git ls-remote -h ssh://my.git.server/git/test.git # timeout=10
      Found 3 remote heads on ssh://my.git.server/git/test.git
      [poll] Latest remote head revision on refs/heads/develop is: 9b3f801b5ce8d6649c25ddd4a573801c9a6b5a23 - already built by 4
      Using strategy: Default
      [poll] Last Built Revision: Revision 9b3f801b5ce8d6649c25ddd4a573801c9a6b5a23 (refs/remotes/origin/develop)
       > /usr/bin/git ls-remote -h ssh://my.git.server/git/test.git # timeout=10
      Found 3 remote heads on ssh://my.git.server/git/test.git
      [poll] Latest remote head revision on refs/heads/develop is: 9b3f801b5ce8d6649c25ddd4a573801c9a6b5a23 - already built by 4
      Using strategy: Default
      [poll] Last Built Revision: Revision 9b3f801b5ce8d6649c25ddd4a573801c9a6b5a23 (refs/remotes/origin/develop)
       > /usr/bin/git ls-remote -h ssh://my.git.server/git/test.git # timeout=10
      Found 3 remote heads on ssh://my.git.server/git/test.git
      [poll] Latest remote head revision on refs/heads/system-tests is: afac68d836bc8dcd31826fbd56cb343cf1daf3b5
      Done. Took 0.34 sec
      Changes found
      

      I tried recreating the job, test branch... no use...

      Appreciate your help here.

      Thanks

        Attachments

          Issue Links

            Activity

            Hide
            0x89 Martin Sander added a comment -

            Mark Waite:

            Yes, I think I did - kind of - understand why you said that. I just wanted to point out that it does not make a difference if you check out into a separate directory or not - both trigger this behavior.

            I consider checkout of two different repositories into the same directory unsupported and do not ever plan to support it.

            Absolutely agree. Although if this will continue triggering JENKINS-44762, then Jenkins should at least issue a warning when you are trying to do that - it is sometimes hard for a user to recognize that they are making that mistake..

            Show
            0x89 Martin Sander added a comment - Mark Waite : Yes, I think I did - kind of - understand why you said that. I just wanted to point out that it does not make a difference if you check out into a separate directory or not - both trigger this behavior. I consider checkout of two different repositories into the same directory unsupported and do not ever plan to support it. Absolutely agree. Although if this will continue triggering JENKINS-44762 , then Jenkins should at least issue a warning when you are trying to do that - it is sometimes hard for a user to recognize that they are making that mistake..
            Hide
            markewaite Mark Waite added a comment -

            Martin Sander I don't think you've understood why I specifically said "using a separate directory".  

            If you don't use a separate directory for each checkout, then you mingle two different git repositories into a single directory structure.  In the general case, that will cause many different surprises (like "last checkout wins" when both repos have one or more of the same file, or "damaged branch structure information when branch names are the same").  I consider checkout of two different repositories into the same directory unsupported and do not ever plan to support it.

            Show
            markewaite Mark Waite added a comment - Martin Sander I don't think you've understood why I specifically said "using a separate directory".   If you don't use a separate directory for each checkout, then you mingle two different git repositories into a single directory structure.  In the general case, that will cause many different surprises (like "last checkout wins" when both repos have one or more of the same file, or "damaged branch structure information when branch names are the same").  I consider checkout of two different repositories into the same directory unsupported and do not ever plan to support it.
            Hide
            0x89 Martin Sander added a comment -

            Leibo could you try providing a minimal example so that we can differentiate from JENKINS-44762?

            Show
            0x89 Martin Sander added a comment - Leibo could you try providing a minimal example so that we can differentiate from JENKINS-44762 ?
            Hide
            0x89 Martin Sander added a comment -

            Mark Waite:

            where using a Jenkinsfile to checkout two different branches of the same repository into a workspace (using a separate directory for each of the branches)

            "using a separate directory for each of the branches" is not relevant - I was able to reproduce both using different directories and using the same directory, see https://issues.jenkins-ci.org/browse/JENKINS-39621?focusedCommentId=285715&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-285715 and https://issues.jenkins-ci.org/browse/JENKINS-39621?focusedCommentId=285698&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-285698.

            Show
            0x89 Martin Sander added a comment - Mark Waite : where using a Jenkinsfile to checkout two different branches of the same repository into a workspace (using a separate directory for each of the branches) "using a separate directory for each of the branches" is not relevant - I was able to reproduce both using different directories and using the same directory, see https://issues.jenkins-ci.org/browse/JENKINS-39621?focusedCommentId=285715&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-285715 and https://issues.jenkins-ci.org/browse/JENKINS-39621?focusedCommentId=285698&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-285698 .
            Show
            pgeorgiev Pavel Georgiev added a comment - https://issues.jenkins-ci.org/browse/JENKINS-44762

              People

              • Assignee:
                Unassigned
                Reporter:
                assafl Leibo
              • Votes:
                8 Vote for this issue
                Watchers:
                17 Start watching this issue

                Dates

                • Created:
                  Updated: