Class RetryException

All Implemented Interfaces:
Serializable
Direct Known Subclasses:
RateLimitException

public class RetryException extends DbxException
A transient exception has occurred and the request should be retried. Clients should only retry requests after waiting the requested backoff duration (see getBackoffMillis()).
See Also:
  • Constructor Details

    • RetryException

      public RetryException(String requestId, String message)
      Creates an instance of this exception with no retry backoff.
      Parameters:
      requestId - ID assigned to request by Dropbox servers
      message - Error message
    • RetryException

      public RetryException(String requestId, String message, long backoff, TimeUnit unit)
      Creates an instance of this exception with the given retry backoff.
      Parameters:
      requestId - ID assigned to request by Dropbox servers
      message - Error message
      backoff - amount of time to backoff before retrying the request
      unit - unit of time for backoff
  • Method Details

    • getBackoffMillis

      public long getBackoffMillis()
      Returns the number of milliseconds the client should backoff before retrying the request.
      Returns:
      backoff time, in milliseconds, before retrying the request, or 0 if the request can be retried immediately.