org.jclouds.http.handlers
Class DelegatingRetryHandler
java.lang.Object
org.jclouds.http.handlers.DelegatingRetryHandler
- All Implemented Interfaces:
- HttpRetryHandler
@Singleton
public class DelegatingRetryHandler
- extends Object
- implements HttpRetryHandler
Delegates to HttpRetryHandlers
who are annotated according to the
response codes they relate to.
- Author:
- Adrian Cole
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DelegatingRetryHandler
@Inject
public DelegatingRetryHandler(BackoffLimitedRetryHandler backOff,
RedirectionRetryHandler redirectionRetryHandler)
shouldRetryRequest
public boolean shouldRetryRequest(HttpCommand command,
HttpResponse response)
- Description copied from interface:
HttpRetryHandler
- 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.
- Specified by:
shouldRetryRequest
in interface HttpRetryHandler
getRedirectionRetryHandler
public HttpRetryHandler getRedirectionRetryHandler()
getClientErrorRetryHandler
public HttpRetryHandler getClientErrorRetryHandler()
getServerErrorRetryHandler
public HttpRetryHandler getServerErrorRetryHandler()
Copyright © 2009-2011 jclouds. All Rights Reserved.