module Network.AWS.DynamoDB.Types
(
dynamoDB
, _ProvisionedThroughputExceededException
, _ConditionalCheckFailedException
, _ItemCollectionSizeLimitExceededException
, _InternalServerError
, _ResourceNotFoundException
, _ResourceInUseException
, _LimitExceededException
, AttributeAction (..)
, ComparisonOperator (..)
, ConditionalOperator (..)
, IndexStatus (..)
, KeyType (..)
, ProjectionType (..)
, ReturnConsumedCapacity (..)
, ReturnItemCollectionMetrics (..)
, ReturnValue (..)
, ScalarAttributeType (..)
, Select (..)
, StreamViewType (..)
, TableStatus (..)
, AttributeDefinition
, attributeDefinition
, adAttributeName
, adAttributeType
, AttributeValue
, attributeValue
, avL
, avM
, avNS
, avNULL
, avN
, avBS
, avB
, avSS
, avS
, avBOOL
, AttributeValueUpdate
, attributeValueUpdate
, avuValue
, avuAction
, Capacity
, capacity
, cCapacityUnits
, Condition
, condition
, cAttributeValueList
, cComparisonOperator
, ConsumedCapacity
, consumedCapacity
, ccCapacityUnits
, ccGlobalSecondaryIndexes
, ccLocalSecondaryIndexes
, ccTable
, ccTableName
, CreateGlobalSecondaryIndexAction
, createGlobalSecondaryIndexAction
, cgsiaIndexName
, cgsiaKeySchema
, cgsiaProjection
, cgsiaProvisionedThroughput
, DeleteGlobalSecondaryIndexAction
, deleteGlobalSecondaryIndexAction
, dgsiaIndexName
, DeleteRequest
, deleteRequest
, drKey
, ExpectedAttributeValue
, expectedAttributeValue
, eavAttributeValueList
, eavExists
, eavValue
, eavComparisonOperator
, GlobalSecondaryIndex
, globalSecondaryIndex
, gsiIndexName
, gsiKeySchema
, gsiProjection
, gsiProvisionedThroughput
, GlobalSecondaryIndexDescription
, globalSecondaryIndexDescription
, gsidBackfilling
, gsidProvisionedThroughput
, gsidIndexStatus
, gsidIndexSizeBytes
, gsidIndexARN
, gsidKeySchema
, gsidProjection
, gsidItemCount
, gsidIndexName
, GlobalSecondaryIndexUpdate
, globalSecondaryIndexUpdate
, gsiuCreate
, gsiuDelete
, gsiuUpdate
, ItemCollectionMetrics
, itemCollectionMetrics
, icmItemCollectionKey
, icmSizeEstimateRangeGB
, KeySchemaElement
, keySchemaElement
, kseAttributeName
, kseKeyType
, KeysAndAttributes
, keysAndAttributes
, kaaProjectionExpression
, kaaConsistentRead
, kaaExpressionAttributeNames
, kaaAttributesToGet
, kaaKeys
, LocalSecondaryIndex
, localSecondaryIndex
, lsiIndexName
, lsiKeySchema
, lsiProjection
, LocalSecondaryIndexDescription
, localSecondaryIndexDescription
, lsidIndexSizeBytes
, lsidIndexARN
, lsidKeySchema
, lsidProjection
, lsidItemCount
, lsidIndexName
, Projection
, projection
, pProjectionType
, pNonKeyAttributes
, ProvisionedThroughput
, provisionedThroughput
, ptReadCapacityUnits
, ptWriteCapacityUnits
, ProvisionedThroughputDescription
, provisionedThroughputDescription
, ptdReadCapacityUnits
, ptdLastDecreaseDateTime
, ptdWriteCapacityUnits
, ptdNumberOfDecreasesToday
, ptdLastIncreaseDateTime
, PutRequest
, putRequest
, prItem
, StreamSpecification
, streamSpecification
, ssStreamEnabled
, ssStreamViewType
, TableDescription
, tableDescription
, tdProvisionedThroughput
, tdAttributeDefinitions
, tdLatestStreamARN
, tdTableSizeBytes
, tdTableStatus
, tdTableARN
, tdKeySchema
, tdLatestStreamLabel
, tdGlobalSecondaryIndexes
, tdLocalSecondaryIndexes
, tdCreationDateTime
, tdItemCount
, tdTableName
, tdStreamSpecification
, UpdateGlobalSecondaryIndexAction
, updateGlobalSecondaryIndexAction
, ugsiaIndexName
, ugsiaProvisionedThroughput
, WriteRequest
, writeRequest
, wrPutRequest
, wrDeleteRequest
) where
import Network.AWS.DynamoDB.Types.Product
import Network.AWS.DynamoDB.Types.Sum
import Network.AWS.Prelude
import Network.AWS.Sign.V4
dynamoDB :: Service
dynamoDB =
Service
{ _svcAbbrev = "DynamoDB"
, _svcSigner = v4
, _svcPrefix = "dynamodb"
, _svcVersion = "2012-08-10"
, _svcEndpoint = defaultEndpoint dynamoDB
, _svcTimeout = Just 70
, _svcCheck = statusSuccess
, _svcError = parseJSONError
, _svcRetry = retry
}
where
retry =
Exponential
{ _retryBase = 5.0e-2
, _retryGrowth = 2
, _retryAttempts = 5
, _retryCheck = check
}
check e
| has (hasCode "ThrottlingException" . hasStatus 400) e =
Just "throttling_exception"
| has (hasCode "Throttling" . hasStatus 400) e = Just "throttling"
| has
(hasCode "ProvisionedThroughputExceededException" . hasStatus 400)
e =
Just "throughput_exceeded"
| has (hasStatus 503) e = Just "service_unavailable"
| has (hasStatus 500) e = Just "general_server_error"
| has (hasStatus 509) e = Just "limit_exceeded"
| otherwise = Nothing
_ProvisionedThroughputExceededException :: AsError a => Getting (First ServiceError) a ServiceError
_ProvisionedThroughputExceededException =
_ServiceError . hasCode "ProvisionedThroughputExceededException"
_ConditionalCheckFailedException :: AsError a => Getting (First ServiceError) a ServiceError
_ConditionalCheckFailedException =
_ServiceError . hasCode "ConditionalCheckFailedException"
_ItemCollectionSizeLimitExceededException :: AsError a => Getting (First ServiceError) a ServiceError
_ItemCollectionSizeLimitExceededException =
_ServiceError . hasCode "ItemCollectionSizeLimitExceededException"
_InternalServerError :: AsError a => Getting (First ServiceError) a ServiceError
_InternalServerError = _ServiceError . hasCode "InternalServerError"
_ResourceNotFoundException :: AsError a => Getting (First ServiceError) a ServiceError
_ResourceNotFoundException =
_ServiceError . hasCode "ResourceNotFoundException"
_ResourceInUseException :: AsError a => Getting (First ServiceError) a ServiceError
_ResourceInUseException = _ServiceError . hasCode "ResourceInUseException"
_LimitExceededException :: AsError a => Getting (First ServiceError) a ServiceError
_LimitExceededException = _ServiceError . hasCode "LimitExceededException"