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

Excessive branch indexing

    XMLWordPrintable

    Details

    • Similar Issues:

      Description

      I'm using Blue Ocean and the declarative pipeline to describe a job. In the triggers section, I'm only using cron trigger. Nevertheless, Jenkins periodically reruns the job with the message "Branch indexing." The job takes a long time to complete and cleans resources at the beginning, making it very difficult to work with. If there is no pollSCM trigger set, then I don't believe this branch indexing should be occurring.

        Attachments

          Activity

          Hide
          jamesdumay James Dumay added a comment -

          Andrew Bayer I am not sure what might be causing this behaviour. Any ideas?

          Show
          jamesdumay James Dumay added a comment - Andrew Bayer I am not sure what might be causing this behaviour. Any ideas?
          Hide
          abayer Andrew Bayer added a comment -

          That'd be standard multibranch indexing, I'd assume.

          Show
          abayer Andrew Bayer added a comment - That'd be standard multibranch indexing, I'd assume.
          Hide
          stephenconnolly Stephen Connolly added a comment -

          So BlueOcean has some code Vivek Pandey or Keith Zantow added that triggers an index under certain circumstances when a pipeline is saved in BlueOcean... that may be the root cause if indexing is more often than expected by the periodic trigger.

          Alternatively, if there is something sending events to an event hook notifier and those events are missing critical information then the Branch API may have to fall back to triggering a full index... in those cases you should see the event source information in the causes for the branch indexing.

          First place to dig is the causes of the indexing / scan (first line of the the Organization Scan Log / Repository Index Log screen)... if that is saying "Started by timer" then cron is doing the starting... if it says "Started by user ___" then you know it is a user manually triggering... if it is an event (which is how Blue Ocean triggers) then you should see the details of the event source (additional source info should be available as a tooltip on the text after "Started by ..." in the case of events)

          Show
          stephenconnolly Stephen Connolly added a comment - So BlueOcean has some code Vivek Pandey or Keith Zantow added that triggers an index under certain circumstances when a pipeline is saved in BlueOcean... that may be the root cause if indexing is more often than expected by the periodic trigger. Alternatively, if there is something sending events to an event hook notifier and those events are missing critical information then the Branch API may have to fall back to triggering a full index... in those cases you should see the event source information in the causes for the branch indexing. First place to dig is the causes of the indexing / scan (first line of the the Organization Scan Log / Repository Index Log screen)... if that is saying "Started by timer" then cron is doing the starting... if it says "Started by user ___" then you know it is a user manually triggering... if it is an event (which is how Blue Ocean triggers) then you should see the details of the event source (additional source info should be available as a tooltip on the text after "Started by ..." in the case of events)
          Hide
          annetheagile AnneTheAgile added a comment -

          A problem with this method of verifying logs is there is no history of either my main jenkins log nor of this scanning log, right Stephen Connolly ? Also having only a tooltip for part of the message makes it quite opaque.

          I have the problem of extra triggers, but the current scan log is started by timer and it correctly notes my branch was unchanged.

          Today previously twice it reran my job needlessly. (The commit is as of a few days ago.)

          With another problem I just had, I wonder if it might be related to this branch having a period in its name.

          Show
          annetheagile AnneTheAgile added a comment - A problem with this method of verifying logs is there is no history of either my main jenkins log nor of this scanning log, right Stephen Connolly ? Also having only a tooltip for part of the message makes it quite opaque. I have the problem of extra triggers, but the current scan log is started by timer and it correctly notes my branch was unchanged. Today previously twice it reran my job needlessly. (The commit is as of a few days ago.) With another problem I just had, I wonder if it might be related to this branch having a period in its name.
          Hide
          erutan409 Michael Keyser added a comment - - edited

          I'm also seeing this issue.  I just installed this as a clean setup on Ubuntu 16.  My pipelines are using Git on Gitlab, with git URL's and SSH key pair configuration with an admin account in Gitlab.  Not sure what I'd even be looking for in said logs.

          Show
          erutan409 Michael Keyser added a comment - - edited I'm also seeing this issue.  I just installed this as a clean setup on Ubuntu 16.  My pipelines are using Git on Gitlab, with git URL's and SSH key pair configuration with an admin account in Gitlab.  Not sure what I'd even be looking for in said logs.

            People

            Assignee:
            Unassigned Unassigned
            Reporter:
            edahlseng Eric Dahlseng
            Votes:
            1 Vote for this issue
            Watchers:
            11 Start watching this issue

              Dates

              Created:
              Updated: