-
-
Notifications
You must be signed in to change notification settings - Fork 72
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
Add checkout attempts for stability and fix minor issues #50
base: master
Are you sure you want to change the base?
Add checkout attempts for stability and fix minor issues #50
Conversation
SOVALINUX
commented
Aug 27, 2015
- Add checkout attempts, since stats showed it can be very unstable regarding of network
- Fix pom and resource versions
I was thinking about adding checkout property to configuration form, bit not sure, that this is really useful functionality |
@SOVALINUX Sorry for not getting back sooner. Can you shed some more light on this change? What was the scenario you observed and how this fix helps? |
In my logs were a lot of errors that material checkout failed, since git fetch command returned exit code 1 or 128. As I said above it may be caused by network problems. After applying this fix locally it became much better. |
@@ -249,22 +251,27 @@ private GoPluginApiResponse handleCheckout(GoPluginApiRequest goPluginApiRequest | |||
String destinationFolder = (String) requestBodyMap.get("destination-folder"); | |||
Map<String, Object> revisionMap = (Map<String, Object>) requestBodyMap.get("revision"); | |||
String revision = (String) revisionMap.get("revision"); | |||
LOGGER.info(String.format("destination: %s. commit: %s", destinationFolder, revision)); | |||
for (int attempt = 0; attempt < CHECKOUT_ATTEMPTS; attempt++) { | |||
LOGGER.info(String.format("destination: %s. commit: %s, attempt: %s", destinationFolder, revision, attempt)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we also add attempt count as part of the log? It helps while debugging.
Thanks @SOVALINUX. If you could just fix the conflicts, I would merge the changes. |
Conflicts: src/main/java/in/ashwanthkumar/gocd/github/GitHubPRBuildPlugin.java src/main/resources/gerrit/plugin.xml src/main/resources/git/plugin.xml src/main/resources/github/plugin.xml src/main/resources/stash/plugin.xml
@ashwanthkumar - Were the ongoing issues of 128 errors addressed in other PRs or versions that this attempted to address but died on the vine in 2015. |
Any news on this? |