-
Notifications
You must be signed in to change notification settings - Fork 97
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Multibranch Pipeline Branch Scanning Hang(Gitlab Server Error case) #270
Comments
I observe an issue that looks like this one. A scan triggered every minute is now running for over a week. From the log:
|
Just updated another, similar Jenkins job on the same Jenkins server, connected to the same GitLab server, checking from the same owner to use the GitLab Branch Source plugin and it scanned through several times without hanging. Even manually starting a scan while another, time-triggered one is still running does not lead to a hang. |
After a restart of Jenkins, both Jenkins jobs ran through the scan sucessfully several times, again. |
Hello, I have created a branch where I've enabled the timeouts, do you have a good way to reproduce the issue ? I've set the connect- & request-timeout to 60s. |
We also be impacted by the same bug / problem |
@sIuv We are also impacted by this issue frequently and are forced to restart Jenkins on every occurrence of the issue. In order to reproduce the issue please perform the following:
I would really appreciate a fix for this issue, thanks. (Jenkins Version 2.426.3 |
In our case it happened because repo polling was set to 1 minute. We configured the Jenkins integration on (our self-hosted) GitLab's side, which informs Jenkins about pushes etc, we increased repo polling to 1 hour. But I can imagine not everybody is able to do that configuration. |
Jenkins and plugins versions report
Environment
What Operating System are you using (both controller, and any agents involved in the problem)?
OS: Windows Server 2019 (Controller / Agent Both)
Reproduction steps
Step1: Create Multibranch Pipeline Job
Step2: While scanning branch indexing, Gitlab SCM Server occur
Step3: Scanning Task Hang
Expected Results
After minitues, scanning task exception or timeout exception
Actual Results
while fetching branch indexing in a multibrach pipeline job, it getting stuck at scanning branch for days
(As shown in the attached image)
Problmatic thread got stuck in SocketInputStream.socketread0 method(this thread didn't kill by groovy script interrupt or monitoring plugin thread kill/stop)
Anything else?
Timeouts setting(org.gitlab4j.api.GitLabApiClien setRequestTimeout API call in gitlabbranchsource plugin) are needed to solve the above problem.
The same issue can be identified in Bitbuckt/Github source plugin(JENKINS-36724](https://issues.jenkins.io/browse/JENKINS-36724), Bitbucket Hang Timeout Setting Code Commit)
Additonally, it is necessary to provide a jvm system property to set the gitlab timeout for timeout value.(example, java -Dio.jenkins.plugins.gitlabbranchsource.config.readTimeout -Dio.jenkins.plugins.gitlabbranchsource.config.connectTimeout)
If you can, we propose a common SCMSourceRequest interface. This issue occurs in many jenkins sCM source plugin such as gitblab/bitbucket/github, so we need a common interface at Jenkins level that sets the request timeout based on system properties
The text was updated successfully, but these errors were encountered: