> + private int retryCountLimit = 5; > + @Resource > + protected Logger logger = Logger.NULL; > + > + public boolean shouldRetryRequest(HttpCommand command, HttpResponse > response) { > + if (command.getFailureCount() > retryCountLimit) { > + return false; > + } > + if (response.getStatusCode() == 500) { > + byte[] content = > HttpUtils.closeClientButKeepContentStream(response); > + // Content can be null in the case of HEAD requests > + if (content != null) { > + try { > + AtmosError error = utils.parseAtmosErrorFromContent(command, > response, > + new String(content)); > + if (error.getCode() == 1040) { // The server is busy. Please > try again.
I haven't seen these failures myself. I'm fine with the current change if you're not comfortable with retrying on all returned error codes except 1020. --- Reply to this email directly or view it on GitHub: https://github.com/jclouds/jclouds/pull/285/files#r9637835