[JIRA] (JENKINS-38973) Multibranch-Pipeline Not Honoring Git Timeout

23 views
Skip to first unread message

da.johnson.a@gmail.com (JIRA)

unread,
Oct 13, 2016, 4:19:02 PM10/13/16
to jenkinsc...@googlegroups.com
David Johnson created an issue
 
Jenkins / Bug JENKINS-38973
Multibranch-Pipeline Not Honoring Git Timeout
Issue Type: Bug Bug
Assignee: Mark Waite
Attachments: error.txt, Screen Shot 2016-10-13 at 15.39.47.png, Screen Shot 2016-10-13 at 15.41.59.png, Screen Shot 2016-10-13 at 15.42.03.png, Screen Shot 2016-10-13 at 15.42.06.png
Components: git-client-plugin, git-plugin, multi-branch-project-plugin
Created: 2016/Oct/13 8:18 PM
Environment: Jenkins 2.19.1
Git client plugin 2.0.0
Git plugin 3.0.0
Pipeline: Multibranch: 2.9
Priority: Major Major
Reporter: David Johnson

I am having an issue cloning a large repo for use in a multi-branch pipeline project.

My goal is to run pipeline jobs against certain branches within my repository. However, the initial fetch seems to timeout. As you can see from the attached log, the issue appears to arise from a 10 minute timeout issue. However, if you see the below screen shots, I have all of my timeouts set to 180minutes.

In the attached tickets there were known issues with the 10 minute git timeout that were fixed by allowing users access to overrides as I have shown in the attached images. It appears as though these overrides are not being honored for some reason within the MultibranchPipeline project.

I have used the settings described here on a smaller repo and it was able to properly index the branches.

As a work around, I also tried only using the overrides as advanced settings for checkout/fetch behavior. This did not work either, unfortunately.

Add Comment Add Comment
 
This message was sent by Atlassian JIRA (v7.1.7#71011-sha1:2526d7c)
Atlassian logo

mark.earl.waite@gmail.com (JIRA)

unread,
Oct 13, 2016, 4:22:02 PM10/13/16
to jenkinsc...@googlegroups.com
Mark Waite assigned an issue to Unassigned
Change By: Mark Waite
Assignee: Mark Waite

erik.hakansson@wirelesscar.com (JIRA)

unread,
Oct 21, 2016, 4:02:01 AM10/21/16
to jenkinsc...@googlegroups.com
Erik Hakansson commented on Bug JENKINS-38973
 
Re: Multibranch-Pipeline Not Honoring Git Timeout

We have this issue too. Always timeout on indexing.

erik.hakansson@wirelesscar.com (JIRA)

unread,
Oct 24, 2016, 8:33:01 AM10/24/16
to jenkinsc...@googlegroups.com

This pull request to Git client plugin makes the default timeout configurable and should solve this issue.

orkru666@gmail.com (JIRA)

unread,
Feb 17, 2017, 11:47:01 AM2/17/17
to jenkinsc...@googlegroups.com

Huge blocker. Needs to be fixed.
Any available workarounds?

tsiegmund@crowd-architects.com (JIRA)

unread,
Mar 1, 2017, 8:13:02 AM3/1/17
to jenkinsc...@googlegroups.com

Same problem here. Tryed to manually pre clone the repository does not help.

zeratul.25@gmail.com (JIRA)

unread,
Mar 11, 2017, 12:08:02 PM3/11/17
to jenkinsc...@googlegroups.com

This is suddenly an issue for me. I'm not sure the timeout is the culprit, as it used to clone fine, but now some problem with the git fetch does cause the timeout to expire.

Additionally, this doesn't read as a failure on the git fetch for the multibranch pipeline project, it just stays locked on this git fetch process preventing other jobs from running. Perhaps this is another issue that should have a new bug opened?

This message was sent by Atlassian JIRA (v7.3.0#73011-sha1:3c73d0e)
Atlassian logo

mark.earl.waite@gmail.com (JIRA)

unread,
Mar 11, 2017, 12:51:03 PM3/11/17
to jenkinsc...@googlegroups.com

An alternative might be to pass -Dorg.jenkinsci.plugins.gitclient.Git.timeOut=37 as a Java command line option to Jenkins. That will set the Jenkins global git timeout to 37 minutes instead of its default of 10 minutes.

I don't know why the pipeline initial clone ignores the timeout setting, but I've confirmed that it does ignore it.

I confirmed it is ignored with the following steps:

  1. Create a multi-branch pipeline job with Git as the SCM source
  2. Use https://github.com/torvalds/linux.git as the repository location
  3. Add the "Additional Behaviour" for "Advanced clone options"
  4. Set the timeout to a small value (1 or 2)
  5. Click the "Scan Multibranch Pipeline Now" link
  6. Monitor the progress of the clone, note that it will run longer than the assigned timeout value. Other cases honor the timeout, but apparently not that case

asenjo1989@gmail.com (JIRA)

unread,
Mar 15, 2018, 5:00:08 AM3/15/18
to jenkinsc...@googlegroups.com

lostinberlin2010@gmail.com (JIRA)

unread,
May 8, 2018, 2:23:05 AM5/8/18
to jenkinsc...@googlegroups.com

Hi,

I second guillaume docquier's comment. Our git repository is close to 5GB in size and the local git repository is not being used at all when running "Branch Indexing".

Antonio Asenjo: thanks for the link but setting the timeout option higher is not really a long term solution since we have a large number of pipelines with all require branch indexing meaning the 5GB will be duplicated many times on the master.

I too would like to see a solution for this. I will have a look into the code when I have time but I don't know when this will be.

 

shoareau@gmail.com (JIRA)

unread,
Mar 29, 2019, 10:20:03 AM3/29/19
to jenkinsc...@googlegroups.com

Not exactly the same, but we have a similar problem with the shallow clone option: the plugin doesn't seem to take into account either (no --depth=xx on the git fetch command line)

This message was sent by Atlassian Jira (v7.11.2#711002-sha1:fdc329d)

Rohit_Gagan@hotmail.com (JIRA)

unread,
May 22, 2019, 9:59:03 AM5/22/19
to jenkinsc...@googlegroups.com

Any resolution to this issue. Still facing the same problem

mark.earl.waite@gmail.com (JIRA)

unread,
May 22, 2019, 10:25:09 AM5/22/19
to jenkinsc...@googlegroups.com

mark.earl.waite@gmail.com (JIRA)

unread,
May 22, 2019, 10:26:02 AM5/22/19
to jenkinsc...@googlegroups.com
Mark Waite edited a comment on Bug JENKINS-38973
No [~rohit_gagan], the best work around is still the [stackoverflow article|https://stackoverflow.com/a/37133464] referenced by [~aseg] . Since branch indexing happens on the master and uses a known cache, it should create only a single copy of the large repository, then it will reuse that for additional operations.

Rohit_Gagan@hotmail.com (JIRA)

unread,
May 22, 2019, 11:59:02 AM5/22/19
to jenkinsc...@googlegroups.com

Mark Waite. Tried adding that, this still takes timeout as 10 min

 

Started
[Wed May 22 11:55:15 EDT 2019] Starting branch indexing...
> git --version # timeout=10

Rohit_Gagan@hotmail.com (JIRA)

unread,
May 22, 2019, 12:12:04 PM5/22/19
to jenkinsc...@googlegroups.com

Mark Waite only option i see is change in git plugin code then to increase the default timeout. What you suggest?

 

Rohit_Gagan@hotmail.com (JIRA)

unread,
May 22, 2019, 1:51:05 PM5/22/19
to jenkinsc...@googlegroups.com

Mark Waite. Thanks. This works. i was adding the parameter at the wrong end

mark.earl.waite@gmail.com (JIRA)

unread,
Jul 4, 2019, 12:26:03 PM7/4/19
to jenkinsc...@googlegroups.com
Mark Waite updated an issue
 
Change By: Mark Waite
Component/s: multi-branch-project-plugin (not Pipeline)
Reply all
Reply to author
Forward
0 new messages