org.jclouds.http
Interface HttpRetryHandler

All Known Implementing Classes:
AtmosClientErrorRetryHandler, AWSClientErrorRetryHandler, AzureStorageClientErrorRetryHandler, BackoffLimitedRetryHandler, DelegatingRetryHandler, DeltacloudRedirectionRetryHandler, InvalidateSessionAndRetryOn401AndLogoutOnClose, RedirectionRetryHandler, RetryOnRenew, RetryOnRenew, RetryOnRenew, S3RedirectionRetryHandler

public interface HttpRetryHandler

Indicate whether a request should be retried after a server error response (HTTP status code >= 500) based on the request's replayable status and the number of attempts already performed.

Author:
James Murty

Field Summary
static HttpRetryHandler ALWAYS_RETRY
           
static HttpRetryHandler NEVER_RETRY
           
 
Method Summary
 boolean shouldRetryRequest(HttpCommand command, HttpResponse response)
          Return true if the command should be retried.
 

Field Detail

ALWAYS_RETRY

static final HttpRetryHandler ALWAYS_RETRY

NEVER_RETRY

static final HttpRetryHandler NEVER_RETRY
Method Detail

shouldRetryRequest

boolean shouldRetryRequest(HttpCommand command,
                           HttpResponse response)
Return true if the command should be retried. This method should only be invoked when the response has failed with a HTTP 5xx error indicating a server-side error.



Copyright © 2009-2012 jclouds. All Rights Reserved.