-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Make checkout lock failure retryable #177
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
Conversation
plugins » git-plugin #155 FAILURE |
The build failed, but it should not be my fault. |
Thank you for a pull request! Please check this document for how the Jenkins project handles pull requests |
plugins » git-plugin #162 SUCCESS |
@ndeloof Do you have any opinion on this? |
My sole concern is that with this change we consider all GitException during checkout to be retryable, even some may be a fatal error. Should only consider a well identified subset, maybe based on root exception message. |
It makes sense, indeed. public class GitLockFailedException extends GitException {} in git-client-plugin and catching it selectively on git-plugin side? |
plugins » git-plugin #197 FAILURE |
plugins » git-plugin #211 UNSTABLE |
plugins » git-plugin #223 SUCCESS |
plugins » git-plugin #230 UNSTABLE |
@ndeloof Any thoughts? |
Make checkout lock failure retryable
Great thanks! |
In a shared workspace environment, git checkout occasionally fails because another concurrent build has lock on the git repository(.git/index.lock).
(e.g http://jenkins-ci.361315.n4.nabble.com/Git-index-lock-problem-on-a-common-directory-td4488918.html)
This change resolves this problem by rethrowing IOException on lock failure to make operation retryable.
Refs: jenkinsci/git-client-plugin#31, jenkinsci/git-client-plugin#17