{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}
module Amazonka.CloudWatchEvents.Types
(
defaultService,
_ManagedRuleException,
_IllegalStatusException,
_PolicyLengthExceededException,
_ResourceAlreadyExistsException,
_OperationDisabledException,
_ConcurrentModificationException,
_InvalidEventPatternException,
_InternalException,
_ResourceNotFoundException,
_InvalidStateException,
_LimitExceededException,
ApiDestinationHttpMethod (..),
ApiDestinationState (..),
ArchiveState (..),
AssignPublicIp (..),
ConnectionAuthorizationType (..),
ConnectionOAuthHttpMethod (..),
ConnectionState (..),
EventSourceState (..),
LaunchType (..),
PlacementConstraintType (..),
PlacementStrategyType (..),
PropagateTags (..),
ReplayState (..),
RuleState (..),
ApiDestination (..),
newApiDestination,
apiDestination_creationTime,
apiDestination_httpMethod,
apiDestination_invocationEndpoint,
apiDestination_lastModifiedTime,
apiDestination_name,
apiDestination_invocationRateLimitPerSecond,
apiDestination_apiDestinationState,
apiDestination_connectionArn,
apiDestination_apiDestinationArn,
Archive (..),
newArchive,
archive_creationTime,
archive_sizeBytes,
archive_eventSourceArn,
archive_state,
archive_eventCount,
archive_archiveName,
archive_retentionDays,
archive_stateReason,
AwsVpcConfiguration (..),
newAwsVpcConfiguration,
awsVpcConfiguration_securityGroups,
awsVpcConfiguration_assignPublicIp,
awsVpcConfiguration_subnets,
BatchArrayProperties (..),
newBatchArrayProperties,
batchArrayProperties_size,
BatchParameters (..),
newBatchParameters,
batchParameters_retryStrategy,
batchParameters_arrayProperties,
batchParameters_jobDefinition,
batchParameters_jobName,
BatchRetryStrategy (..),
newBatchRetryStrategy,
batchRetryStrategy_attempts,
CapacityProviderStrategyItem (..),
newCapacityProviderStrategyItem,
capacityProviderStrategyItem_base,
capacityProviderStrategyItem_weight,
capacityProviderStrategyItem_capacityProvider,
Condition (..),
newCondition,
condition_type,
condition_key,
condition_value,
Connection (..),
newConnection,
connection_creationTime,
connection_lastModifiedTime,
connection_name,
connection_lastAuthorizedTime,
connection_authorizationType,
connection_connectionArn,
connection_stateReason,
connection_connectionState,
ConnectionApiKeyAuthResponseParameters (..),
newConnectionApiKeyAuthResponseParameters,
connectionApiKeyAuthResponseParameters_apiKeyName,
ConnectionAuthResponseParameters (..),
newConnectionAuthResponseParameters,
connectionAuthResponseParameters_oAuthParameters,
connectionAuthResponseParameters_invocationHttpParameters,
connectionAuthResponseParameters_apiKeyAuthParameters,
connectionAuthResponseParameters_basicAuthParameters,
ConnectionBasicAuthResponseParameters (..),
newConnectionBasicAuthResponseParameters,
connectionBasicAuthResponseParameters_username,
ConnectionBodyParameter (..),
newConnectionBodyParameter,
connectionBodyParameter_isValueSecret,
connectionBodyParameter_value,
connectionBodyParameter_key,
ConnectionHeaderParameter (..),
newConnectionHeaderParameter,
connectionHeaderParameter_isValueSecret,
connectionHeaderParameter_value,
connectionHeaderParameter_key,
ConnectionHttpParameters (..),
newConnectionHttpParameters,
connectionHttpParameters_queryStringParameters,
connectionHttpParameters_headerParameters,
connectionHttpParameters_bodyParameters,
ConnectionOAuthClientResponseParameters (..),
newConnectionOAuthClientResponseParameters,
connectionOAuthClientResponseParameters_clientID,
ConnectionOAuthResponseParameters (..),
newConnectionOAuthResponseParameters,
connectionOAuthResponseParameters_httpMethod,
connectionOAuthResponseParameters_clientParameters,
connectionOAuthResponseParameters_oAuthHttpParameters,
connectionOAuthResponseParameters_authorizationEndpoint,
ConnectionQueryStringParameter (..),
newConnectionQueryStringParameter,
connectionQueryStringParameter_isValueSecret,
connectionQueryStringParameter_value,
connectionQueryStringParameter_key,
CreateConnectionApiKeyAuthRequestParameters (..),
newCreateConnectionApiKeyAuthRequestParameters,
createConnectionApiKeyAuthRequestParameters_apiKeyName,
createConnectionApiKeyAuthRequestParameters_apiKeyValue,
CreateConnectionAuthRequestParameters (..),
newCreateConnectionAuthRequestParameters,
createConnectionAuthRequestParameters_oAuthParameters,
createConnectionAuthRequestParameters_invocationHttpParameters,
createConnectionAuthRequestParameters_apiKeyAuthParameters,
createConnectionAuthRequestParameters_basicAuthParameters,
CreateConnectionBasicAuthRequestParameters (..),
newCreateConnectionBasicAuthRequestParameters,
createConnectionBasicAuthRequestParameters_username,
createConnectionBasicAuthRequestParameters_password,
CreateConnectionOAuthClientRequestParameters (..),
newCreateConnectionOAuthClientRequestParameters,
createConnectionOAuthClientRequestParameters_clientID,
createConnectionOAuthClientRequestParameters_clientSecret,
CreateConnectionOAuthRequestParameters (..),
newCreateConnectionOAuthRequestParameters,
createConnectionOAuthRequestParameters_oAuthHttpParameters,
createConnectionOAuthRequestParameters_clientParameters,
createConnectionOAuthRequestParameters_authorizationEndpoint,
createConnectionOAuthRequestParameters_httpMethod,
DeadLetterConfig (..),
newDeadLetterConfig,
deadLetterConfig_arn,
EcsParameters (..),
newEcsParameters,
ecsParameters_group,
ecsParameters_propagateTags,
ecsParameters_platformVersion,
ecsParameters_enableECSManagedTags,
ecsParameters_referenceId,
ecsParameters_placementConstraints,
ecsParameters_placementStrategy,
ecsParameters_launchType,
ecsParameters_capacityProviderStrategy,
ecsParameters_taskCount,
ecsParameters_networkConfiguration,
ecsParameters_tags,
ecsParameters_enableExecuteCommand,
ecsParameters_taskDefinitionArn,
EventBus (..),
newEventBus,
eventBus_arn,
eventBus_name,
eventBus_policy,
EventSource (..),
newEventSource,
eventSource_creationTime,
eventSource_state,
eventSource_arn,
eventSource_createdBy,
eventSource_name,
eventSource_expirationTime,
HttpParameters (..),
newHttpParameters,
httpParameters_pathParameterValues,
httpParameters_queryStringParameters,
httpParameters_headerParameters,
InputTransformer (..),
newInputTransformer,
inputTransformer_inputPathsMap,
inputTransformer_inputTemplate,
KinesisParameters (..),
newKinesisParameters,
kinesisParameters_partitionKeyPath,
NetworkConfiguration (..),
newNetworkConfiguration,
networkConfiguration_awsvpcConfiguration,
PartnerEventSource (..),
newPartnerEventSource,
partnerEventSource_arn,
partnerEventSource_name,
PartnerEventSourceAccount (..),
newPartnerEventSourceAccount,
partnerEventSourceAccount_creationTime,
partnerEventSourceAccount_state,
partnerEventSourceAccount_account,
partnerEventSourceAccount_expirationTime,
PlacementConstraint (..),
newPlacementConstraint,
placementConstraint_expression,
placementConstraint_type,
PlacementStrategy (..),
newPlacementStrategy,
placementStrategy_field,
placementStrategy_type,
PutEventsRequestEntry (..),
newPutEventsRequestEntry,
putEventsRequestEntry_time,
putEventsRequestEntry_detailType,
putEventsRequestEntry_resources,
putEventsRequestEntry_eventBusName,
putEventsRequestEntry_source,
putEventsRequestEntry_traceHeader,
putEventsRequestEntry_detail,
PutEventsResultEntry (..),
newPutEventsResultEntry,
putEventsResultEntry_errorCode,
putEventsResultEntry_errorMessage,
putEventsResultEntry_eventId,
PutPartnerEventsRequestEntry (..),
newPutPartnerEventsRequestEntry,
putPartnerEventsRequestEntry_time,
putPartnerEventsRequestEntry_detailType,
putPartnerEventsRequestEntry_resources,
putPartnerEventsRequestEntry_source,
putPartnerEventsRequestEntry_detail,
PutPartnerEventsResultEntry (..),
newPutPartnerEventsResultEntry,
putPartnerEventsResultEntry_errorCode,
putPartnerEventsResultEntry_errorMessage,
putPartnerEventsResultEntry_eventId,
PutTargetsResultEntry (..),
newPutTargetsResultEntry,
putTargetsResultEntry_targetId,
putTargetsResultEntry_errorCode,
putTargetsResultEntry_errorMessage,
RedshiftDataParameters (..),
newRedshiftDataParameters,
redshiftDataParameters_dbUser,
redshiftDataParameters_secretManagerArn,
redshiftDataParameters_statementName,
redshiftDataParameters_withEvent,
redshiftDataParameters_database,
redshiftDataParameters_sql,
RemoveTargetsResultEntry (..),
newRemoveTargetsResultEntry,
removeTargetsResultEntry_targetId,
removeTargetsResultEntry_errorCode,
removeTargetsResultEntry_errorMessage,
Replay (..),
newReplay,
replay_eventSourceArn,
replay_state,
replay_eventEndTime,
replay_replayStartTime,
replay_replayEndTime,
replay_eventLastReplayedTime,
replay_eventStartTime,
replay_replayName,
replay_stateReason,
ReplayDestination (..),
newReplayDestination,
replayDestination_filterArns,
replayDestination_arn,
RetryPolicy (..),
newRetryPolicy,
retryPolicy_maximumEventAgeInSeconds,
retryPolicy_maximumRetryAttempts,
Rule (..),
newRule,
rule_eventPattern,
rule_state,
rule_arn,
rule_eventBusName,
rule_scheduleExpression,
rule_name,
rule_description,
rule_managedBy,
rule_roleArn,
RunCommandParameters (..),
newRunCommandParameters,
runCommandParameters_runCommandTargets,
RunCommandTarget (..),
newRunCommandTarget,
runCommandTarget_key,
runCommandTarget_values,
SageMakerPipelineParameter (..),
newSageMakerPipelineParameter,
sageMakerPipelineParameter_name,
sageMakerPipelineParameter_value,
SageMakerPipelineParameters (..),
newSageMakerPipelineParameters,
sageMakerPipelineParameters_pipelineParameterList,
SqsParameters (..),
newSqsParameters,
sqsParameters_messageGroupId,
Tag (..),
newTag,
tag_key,
tag_value,
Target (..),
newTarget,
target_runCommandParameters,
target_httpParameters,
target_kinesisParameters,
target_inputTransformer,
target_deadLetterConfig,
target_sageMakerPipelineParameters,
target_sqsParameters,
target_input,
target_batchParameters,
target_redshiftDataParameters,
target_ecsParameters,
target_retryPolicy,
target_inputPath,
target_roleArn,
target_id,
target_arn,
UpdateConnectionApiKeyAuthRequestParameters (..),
newUpdateConnectionApiKeyAuthRequestParameters,
updateConnectionApiKeyAuthRequestParameters_apiKeyValue,
updateConnectionApiKeyAuthRequestParameters_apiKeyName,
UpdateConnectionAuthRequestParameters (..),
newUpdateConnectionAuthRequestParameters,
updateConnectionAuthRequestParameters_oAuthParameters,
updateConnectionAuthRequestParameters_invocationHttpParameters,
updateConnectionAuthRequestParameters_apiKeyAuthParameters,
updateConnectionAuthRequestParameters_basicAuthParameters,
UpdateConnectionBasicAuthRequestParameters (..),
newUpdateConnectionBasicAuthRequestParameters,
updateConnectionBasicAuthRequestParameters_username,
updateConnectionBasicAuthRequestParameters_password,
UpdateConnectionOAuthClientRequestParameters (..),
newUpdateConnectionOAuthClientRequestParameters,
updateConnectionOAuthClientRequestParameters_clientID,
updateConnectionOAuthClientRequestParameters_clientSecret,
UpdateConnectionOAuthRequestParameters (..),
newUpdateConnectionOAuthRequestParameters,
updateConnectionOAuthRequestParameters_httpMethod,
updateConnectionOAuthRequestParameters_clientParameters,
updateConnectionOAuthRequestParameters_oAuthHttpParameters,
updateConnectionOAuthRequestParameters_authorizationEndpoint,
)
where
import Amazonka.CloudWatchEvents.Types.ApiDestination
import Amazonka.CloudWatchEvents.Types.ApiDestinationHttpMethod
import Amazonka.CloudWatchEvents.Types.ApiDestinationState
import Amazonka.CloudWatchEvents.Types.Archive
import Amazonka.CloudWatchEvents.Types.ArchiveState
import Amazonka.CloudWatchEvents.Types.AssignPublicIp
import Amazonka.CloudWatchEvents.Types.AwsVpcConfiguration
import Amazonka.CloudWatchEvents.Types.BatchArrayProperties
import Amazonka.CloudWatchEvents.Types.BatchParameters
import Amazonka.CloudWatchEvents.Types.BatchRetryStrategy
import Amazonka.CloudWatchEvents.Types.CapacityProviderStrategyItem
import Amazonka.CloudWatchEvents.Types.Condition
import Amazonka.CloudWatchEvents.Types.Connection
import Amazonka.CloudWatchEvents.Types.ConnectionApiKeyAuthResponseParameters
import Amazonka.CloudWatchEvents.Types.ConnectionAuthResponseParameters
import Amazonka.CloudWatchEvents.Types.ConnectionAuthorizationType
import Amazonka.CloudWatchEvents.Types.ConnectionBasicAuthResponseParameters
import Amazonka.CloudWatchEvents.Types.ConnectionBodyParameter
import Amazonka.CloudWatchEvents.Types.ConnectionHeaderParameter
import Amazonka.CloudWatchEvents.Types.ConnectionHttpParameters
import Amazonka.CloudWatchEvents.Types.ConnectionOAuthClientResponseParameters
import Amazonka.CloudWatchEvents.Types.ConnectionOAuthHttpMethod
import Amazonka.CloudWatchEvents.Types.ConnectionOAuthResponseParameters
import Amazonka.CloudWatchEvents.Types.ConnectionQueryStringParameter
import Amazonka.CloudWatchEvents.Types.ConnectionState
import Amazonka.CloudWatchEvents.Types.CreateConnectionApiKeyAuthRequestParameters
import Amazonka.CloudWatchEvents.Types.CreateConnectionAuthRequestParameters
import Amazonka.CloudWatchEvents.Types.CreateConnectionBasicAuthRequestParameters
import Amazonka.CloudWatchEvents.Types.CreateConnectionOAuthClientRequestParameters
import Amazonka.CloudWatchEvents.Types.CreateConnectionOAuthRequestParameters
import Amazonka.CloudWatchEvents.Types.DeadLetterConfig
import Amazonka.CloudWatchEvents.Types.EcsParameters
import Amazonka.CloudWatchEvents.Types.EventBus
import Amazonka.CloudWatchEvents.Types.EventSource
import Amazonka.CloudWatchEvents.Types.EventSourceState
import Amazonka.CloudWatchEvents.Types.HttpParameters
import Amazonka.CloudWatchEvents.Types.InputTransformer
import Amazonka.CloudWatchEvents.Types.KinesisParameters
import Amazonka.CloudWatchEvents.Types.LaunchType
import Amazonka.CloudWatchEvents.Types.NetworkConfiguration
import Amazonka.CloudWatchEvents.Types.PartnerEventSource
import Amazonka.CloudWatchEvents.Types.PartnerEventSourceAccount
import Amazonka.CloudWatchEvents.Types.PlacementConstraint
import Amazonka.CloudWatchEvents.Types.PlacementConstraintType
import Amazonka.CloudWatchEvents.Types.PlacementStrategy
import Amazonka.CloudWatchEvents.Types.PlacementStrategyType
import Amazonka.CloudWatchEvents.Types.PropagateTags
import Amazonka.CloudWatchEvents.Types.PutEventsRequestEntry
import Amazonka.CloudWatchEvents.Types.PutEventsResultEntry
import Amazonka.CloudWatchEvents.Types.PutPartnerEventsRequestEntry
import Amazonka.CloudWatchEvents.Types.PutPartnerEventsResultEntry
import Amazonka.CloudWatchEvents.Types.PutTargetsResultEntry
import Amazonka.CloudWatchEvents.Types.RedshiftDataParameters
import Amazonka.CloudWatchEvents.Types.RemoveTargetsResultEntry
import Amazonka.CloudWatchEvents.Types.Replay
import Amazonka.CloudWatchEvents.Types.ReplayDestination
import Amazonka.CloudWatchEvents.Types.ReplayState
import Amazonka.CloudWatchEvents.Types.RetryPolicy
import Amazonka.CloudWatchEvents.Types.Rule
import Amazonka.CloudWatchEvents.Types.RuleState
import Amazonka.CloudWatchEvents.Types.RunCommandParameters
import Amazonka.CloudWatchEvents.Types.RunCommandTarget
import Amazonka.CloudWatchEvents.Types.SageMakerPipelineParameter
import Amazonka.CloudWatchEvents.Types.SageMakerPipelineParameters
import Amazonka.CloudWatchEvents.Types.SqsParameters
import Amazonka.CloudWatchEvents.Types.Tag
import Amazonka.CloudWatchEvents.Types.Target
import Amazonka.CloudWatchEvents.Types.UpdateConnectionApiKeyAuthRequestParameters
import Amazonka.CloudWatchEvents.Types.UpdateConnectionAuthRequestParameters
import Amazonka.CloudWatchEvents.Types.UpdateConnectionBasicAuthRequestParameters
import Amazonka.CloudWatchEvents.Types.UpdateConnectionOAuthClientRequestParameters
import Amazonka.CloudWatchEvents.Types.UpdateConnectionOAuthRequestParameters
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Sign.V4 as Sign
defaultService :: Core.Service
defaultService :: Service
defaultService =
Service :: Abbrev
-> Signer
-> ByteString
-> ByteString
-> ByteString
-> (Region -> Endpoint)
-> Maybe Seconds
-> (Status -> Bool)
-> (Status -> [Header] -> ByteStringLazy -> Error)
-> Retry
-> Service
Core.Service
{ $sel:_serviceAbbrev:Service :: Abbrev
Core._serviceAbbrev =
Abbrev
"CloudWatchEvents",
$sel:_serviceSigner:Service :: Signer
Core._serviceSigner = Signer
Sign.v4,
$sel:_serviceEndpointPrefix:Service :: ByteString
Core._serviceEndpointPrefix = ByteString
"events",
$sel:_serviceSigningName:Service :: ByteString
Core._serviceSigningName = ByteString
"events",
$sel:_serviceVersion:Service :: ByteString
Core._serviceVersion = ByteString
"2015-10-07",
$sel:_serviceEndpoint:Service :: Region -> Endpoint
Core._serviceEndpoint =
Service -> Region -> Endpoint
Core.defaultEndpoint Service
defaultService,
$sel:_serviceTimeout:Service :: Maybe Seconds
Core._serviceTimeout = Seconds -> Maybe Seconds
forall a. a -> Maybe a
Prelude.Just Seconds
70,
$sel:_serviceCheck:Service :: Status -> Bool
Core._serviceCheck = Status -> Bool
Core.statusSuccess,
$sel:_serviceError:Service :: Status -> [Header] -> ByteStringLazy -> Error
Core._serviceError =
Abbrev -> Status -> [Header] -> ByteStringLazy -> Error
Core.parseJSONError Abbrev
"CloudWatchEvents",
$sel:_serviceRetry:Service :: Retry
Core._serviceRetry = Retry
retry
}
where
retry :: Retry
retry =
Exponential :: Double -> Int -> Int -> (ServiceError -> Maybe Text) -> Retry
Core.Exponential
{ $sel:_retryBase:Exponential :: Double
Core._retryBase = Double
5.0e-2,
$sel:_retryGrowth:Exponential :: Int
Core._retryGrowth = Int
2,
$sel:_retryAttempts:Exponential :: Int
Core._retryAttempts = Int
5,
$sel:_retryCheck:Exponential :: ServiceError -> Maybe Text
Core._retryCheck = ServiceError -> Maybe Text
forall a. IsString a => ServiceError -> Maybe a
check
}
check :: ServiceError -> Maybe a
check ServiceError
e
| Getting Any ServiceError ServiceError -> ServiceError -> Bool
forall s a. Getting Any s a -> s -> Bool
Lens.has
( ErrorCode -> Getting Any ServiceError ServiceError
forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
ErrorCode -> Optic' p f ServiceError ServiceError
Core.hasCode ErrorCode
"ThrottledException"
Getting Any ServiceError ServiceError
-> Getting Any ServiceError ServiceError
-> Getting Any ServiceError ServiceError
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. Int -> Getting Any ServiceError ServiceError
forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
400
)
ServiceError
e =
a -> Maybe a
forall a. a -> Maybe a
Prelude.Just a
"throttled_exception"
| Getting Any ServiceError ServiceError -> ServiceError -> Bool
forall s a. Getting Any s a -> s -> Bool
Lens.has (Int -> Getting Any ServiceError ServiceError
forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
429) ServiceError
e =
a -> Maybe a
forall a. a -> Maybe a
Prelude.Just a
"too_many_requests"
| Getting Any ServiceError ServiceError -> ServiceError -> Bool
forall s a. Getting Any s a -> s -> Bool
Lens.has
( ErrorCode -> Getting Any ServiceError ServiceError
forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
ErrorCode -> Optic' p f ServiceError ServiceError
Core.hasCode ErrorCode
"ThrottlingException"
Getting Any ServiceError ServiceError
-> Getting Any ServiceError ServiceError
-> Getting Any ServiceError ServiceError
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. Int -> Getting Any ServiceError ServiceError
forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
400
)
ServiceError
e =
a -> Maybe a
forall a. a -> Maybe a
Prelude.Just a
"throttling_exception"
| Getting Any ServiceError ServiceError -> ServiceError -> Bool
forall s a. Getting Any s a -> s -> Bool
Lens.has
( ErrorCode -> Getting Any ServiceError ServiceError
forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
ErrorCode -> Optic' p f ServiceError ServiceError
Core.hasCode ErrorCode
"Throttling"
Getting Any ServiceError ServiceError
-> Getting Any ServiceError ServiceError
-> Getting Any ServiceError ServiceError
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. Int -> Getting Any ServiceError ServiceError
forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
400
)
ServiceError
e =
a -> Maybe a
forall a. a -> Maybe a
Prelude.Just a
"throttling"
| Getting Any ServiceError ServiceError -> ServiceError -> Bool
forall s a. Getting Any s a -> s -> Bool
Lens.has
( ErrorCode -> Getting Any ServiceError ServiceError
forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
ErrorCode -> Optic' p f ServiceError ServiceError
Core.hasCode
ErrorCode
"ProvisionedThroughputExceededException"
Getting Any ServiceError ServiceError
-> Getting Any ServiceError ServiceError
-> Getting Any ServiceError ServiceError
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. Int -> Getting Any ServiceError ServiceError
forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
400
)
ServiceError
e =
a -> Maybe a
forall a. a -> Maybe a
Prelude.Just a
"throughput_exceeded"
| Getting Any ServiceError ServiceError -> ServiceError -> Bool
forall s a. Getting Any s a -> s -> Bool
Lens.has (Int -> Getting Any ServiceError ServiceError
forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
504) ServiceError
e =
a -> Maybe a
forall a. a -> Maybe a
Prelude.Just a
"gateway_timeout"
| Getting Any ServiceError ServiceError -> ServiceError -> Bool
forall s a. Getting Any s a -> s -> Bool
Lens.has
( ErrorCode -> Getting Any ServiceError ServiceError
forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
ErrorCode -> Optic' p f ServiceError ServiceError
Core.hasCode ErrorCode
"RequestThrottledException"
Getting Any ServiceError ServiceError
-> Getting Any ServiceError ServiceError
-> Getting Any ServiceError ServiceError
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. Int -> Getting Any ServiceError ServiceError
forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
400
)
ServiceError
e =
a -> Maybe a
forall a. a -> Maybe a
Prelude.Just a
"request_throttled_exception"
| Getting Any ServiceError ServiceError -> ServiceError -> Bool
forall s a. Getting Any s a -> s -> Bool
Lens.has (Int -> Getting Any ServiceError ServiceError
forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
502) ServiceError
e =
a -> Maybe a
forall a. a -> Maybe a
Prelude.Just a
"bad_gateway"
| Getting Any ServiceError ServiceError -> ServiceError -> Bool
forall s a. Getting Any s a -> s -> Bool
Lens.has (Int -> Getting Any ServiceError ServiceError
forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
503) ServiceError
e =
a -> Maybe a
forall a. a -> Maybe a
Prelude.Just a
"service_unavailable"
| Getting Any ServiceError ServiceError -> ServiceError -> Bool
forall s a. Getting Any s a -> s -> Bool
Lens.has (Int -> Getting Any ServiceError ServiceError
forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
500) ServiceError
e =
a -> Maybe a
forall a. a -> Maybe a
Prelude.Just a
"general_server_error"
| Getting Any ServiceError ServiceError -> ServiceError -> Bool
forall s a. Getting Any s a -> s -> Bool
Lens.has (Int -> Getting Any ServiceError ServiceError
forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
509) ServiceError
e =
a -> Maybe a
forall a. a -> Maybe a
Prelude.Just a
"limit_exceeded"
| Bool
Prelude.otherwise = Maybe a
forall a. Maybe a
Prelude.Nothing
_ManagedRuleException :: Core.AsError a => Lens.Getting (Prelude.First Core.ServiceError) a Core.ServiceError
_ManagedRuleException :: Getting (First ServiceError) a ServiceError
_ManagedRuleException =
Service -> ErrorCode -> Getting (First ServiceError) a ServiceError
forall a.
AsError a =>
Service -> ErrorCode -> Getting (First ServiceError) a ServiceError
Core._MatchServiceError
Service
defaultService
ErrorCode
"ManagedRuleException"
_IllegalStatusException :: Core.AsError a => Lens.Getting (Prelude.First Core.ServiceError) a Core.ServiceError
_IllegalStatusException :: Getting (First ServiceError) a ServiceError
_IllegalStatusException =
Service -> ErrorCode -> Getting (First ServiceError) a ServiceError
forall a.
AsError a =>
Service -> ErrorCode -> Getting (First ServiceError) a ServiceError
Core._MatchServiceError
Service
defaultService
ErrorCode
"IllegalStatusException"
_PolicyLengthExceededException :: Core.AsError a => Lens.Getting (Prelude.First Core.ServiceError) a Core.ServiceError
_PolicyLengthExceededException :: Getting (First ServiceError) a ServiceError
_PolicyLengthExceededException =
Service -> ErrorCode -> Getting (First ServiceError) a ServiceError
forall a.
AsError a =>
Service -> ErrorCode -> Getting (First ServiceError) a ServiceError
Core._MatchServiceError
Service
defaultService
ErrorCode
"PolicyLengthExceededException"
_ResourceAlreadyExistsException :: Core.AsError a => Lens.Getting (Prelude.First Core.ServiceError) a Core.ServiceError
_ResourceAlreadyExistsException :: Getting (First ServiceError) a ServiceError
_ResourceAlreadyExistsException =
Service -> ErrorCode -> Getting (First ServiceError) a ServiceError
forall a.
AsError a =>
Service -> ErrorCode -> Getting (First ServiceError) a ServiceError
Core._MatchServiceError
Service
defaultService
ErrorCode
"ResourceAlreadyExistsException"
_OperationDisabledException :: Core.AsError a => Lens.Getting (Prelude.First Core.ServiceError) a Core.ServiceError
_OperationDisabledException :: Getting (First ServiceError) a ServiceError
_OperationDisabledException =
Service -> ErrorCode -> Getting (First ServiceError) a ServiceError
forall a.
AsError a =>
Service -> ErrorCode -> Getting (First ServiceError) a ServiceError
Core._MatchServiceError
Service
defaultService
ErrorCode
"OperationDisabledException"
_ConcurrentModificationException :: Core.AsError a => Lens.Getting (Prelude.First Core.ServiceError) a Core.ServiceError
_ConcurrentModificationException :: Getting (First ServiceError) a ServiceError
_ConcurrentModificationException =
Service -> ErrorCode -> Getting (First ServiceError) a ServiceError
forall a.
AsError a =>
Service -> ErrorCode -> Getting (First ServiceError) a ServiceError
Core._MatchServiceError
Service
defaultService
ErrorCode
"ConcurrentModificationException"
_InvalidEventPatternException :: Core.AsError a => Lens.Getting (Prelude.First Core.ServiceError) a Core.ServiceError
_InvalidEventPatternException :: Getting (First ServiceError) a ServiceError
_InvalidEventPatternException =
Service -> ErrorCode -> Getting (First ServiceError) a ServiceError
forall a.
AsError a =>
Service -> ErrorCode -> Getting (First ServiceError) a ServiceError
Core._MatchServiceError
Service
defaultService
ErrorCode
"InvalidEventPatternException"
_InternalException :: Core.AsError a => Lens.Getting (Prelude.First Core.ServiceError) a Core.ServiceError
_InternalException :: Getting (First ServiceError) a ServiceError
_InternalException =
Service -> ErrorCode -> Getting (First ServiceError) a ServiceError
forall a.
AsError a =>
Service -> ErrorCode -> Getting (First ServiceError) a ServiceError
Core._MatchServiceError
Service
defaultService
ErrorCode
"InternalException"
_ResourceNotFoundException :: Core.AsError a => Lens.Getting (Prelude.First Core.ServiceError) a Core.ServiceError
_ResourceNotFoundException :: Getting (First ServiceError) a ServiceError
_ResourceNotFoundException =
Service -> ErrorCode -> Getting (First ServiceError) a ServiceError
forall a.
AsError a =>
Service -> ErrorCode -> Getting (First ServiceError) a ServiceError
Core._MatchServiceError
Service
defaultService
ErrorCode
"ResourceNotFoundException"
_InvalidStateException :: Core.AsError a => Lens.Getting (Prelude.First Core.ServiceError) a Core.ServiceError
_InvalidStateException :: Getting (First ServiceError) a ServiceError
_InvalidStateException =
Service -> ErrorCode -> Getting (First ServiceError) a ServiceError
forall a.
AsError a =>
Service -> ErrorCode -> Getting (First ServiceError) a ServiceError
Core._MatchServiceError
Service
defaultService
ErrorCode
"InvalidStateException"
_LimitExceededException :: Core.AsError a => Lens.Getting (Prelude.First Core.ServiceError) a Core.ServiceError
_LimitExceededException :: Getting (First ServiceError) a ServiceError
_LimitExceededException =
Service -> ErrorCode -> Getting (First ServiceError) a ServiceError
forall a.
AsError a =>
Service -> ErrorCode -> Getting (First ServiceError) a ServiceError
Core._MatchServiceError
Service
defaultService
ErrorCode
"LimitExceededException"