class AWS::DynamoDB::Client

Client class for Amazon DynamoDB.

def extract_error_details response

def extract_error_details response
  if response.http_response.status == 413
    ['RequestEntityTooLarge', 'Request entity too large']
  else
    super
  end
end

def initialize *args

Other tags:
    Private: -
def initialize *args
  super
  # Replaces the current credential provider with a SessionProvider
  # that provides refreshable STS session credentials.  DynamoDB
  # requires session credentials.
  if credential_provider.session_token.nil?
    long_term_credentials = credential_provider.credentials
    @credential_provider = Core::CredentialProviders::SessionProvider.for(
      long_term_credentials)
  end
end

def should_retry? response

def should_retry? response 
  if response.error.is_a?(Errors::ProvisionedThroughputExceededException)
    config.dynamo_db_retry_throughput_errors?
  else
    super
  end
end

def sleep_durations response

def sleep_durations response
  retry_count = 
    if expired_credentials?(response)
      config.max_retries == 0 ? 0 : 1
    else
      config.max_retries { 10 }
    end
  # given a retry_count of 10, the sleep durations will look like:
  # 0, 50, 100, 200, 400, 800, 1600, 3200, 6400, 12800 (milliseconds)
  (0...retry_count).map do |n|
    if n == 0
      0
    else
      50 * (2 ** (n - 1)) / 1000.0
    end
  end
end