{-# LANGUAGE OverloadedStrings #-}
module Network.AWS.ELBv2.Types
(
eLBv2
, _InvalidConfigurationRequestException
, _SubnetNotFoundException
, _TooManyTargetsException
, _RuleNotFoundException
, _InvalidSubnetException
, _TooManyRulesException
, _TooManyTargetGroupsException
, _DuplicateLoadBalancerNameException
, _IncompatibleProtocolsException
, _TooManyCertificatesException
, _DuplicateTagKeysException
, _DuplicateListenerException
, _TooManyTagsException
, _DuplicateTargetGroupNameException
, _HealthUnavailableException
, _AllocationIdNotFoundException
, _PriorityInUseException
, _TooManyLoadBalancersException
, _UnsupportedProtocolException
, _InvalidTargetException
, _InvalidSecurityGroupException
, _TargetGroupNotFoundException
, _ListenerNotFoundException
, _TooManyRegistrationsForTargetIdException
, _TooManyListenersException
, _TargetGroupAssociationLimitException
, _OperationNotPermittedException
, _SSLPolicyNotFoundException
, _InvalidSchemeException
, _AvailabilityZoneNotSupportedException
, _LoadBalancerNotFoundException
, _ResourceInUseException
, _CertificateNotFoundException
, ActionTypeEnum (..)
, IPAddressType (..)
, LoadBalancerSchemeEnum (..)
, LoadBalancerStateEnum (..)
, LoadBalancerTypeEnum (..)
, ProtocolEnum (..)
, TargetHealthReasonEnum (..)
, TargetHealthStateEnum (..)
, TargetTypeEnum (..)
, Action
, action
, aType
, aTargetGroupARN
, AvailabilityZone
, availabilityZone
, azSubnetId
, azZoneName
, azLoadBalancerAddresses
, Certificate
, certificate
, cCertificateARN
, cIsDefault
, Cipher
, cipher
, cPriority
, cName
, Limit
, limit
, lMax
, lName
, Listener
, listener
, lSSLPolicy
, lListenerARN
, lProtocol
, lDefaultActions
, lCertificates
, lLoadBalancerARN
, lPort
, LoadBalancer
, loadBalancer
, lbState
, lbSecurityGroups
, lbLoadBalancerName
, lbCreatedTime
, lbVPCId
, lbCanonicalHostedZoneId
, lbAvailabilityZones
, lbLoadBalancerARN
, lbIPAddressType
, lbScheme
, lbType
, lbDNSName
, LoadBalancerAddress
, loadBalancerAddress
, lbaIPAddress
, lbaAllocationId
, LoadBalancerAttribute
, loadBalancerAttribute
, lbaValue
, lbaKey
, LoadBalancerState
, loadBalancerState
, lbsReason
, lbsCode
, Matcher
, matcher
, mHTTPCode
, Rule
, rule
, rPriority
, rActions
, rConditions
, rRuleARN
, rIsDefault
, RuleCondition
, ruleCondition
, rcField
, rcValues
, RulePriorityPair
, rulePriorityPair
, rppPriority
, rppRuleARN
, SSLPolicy
, sslPolicy
, spCiphers
, spName
, spSSLProtocols
, SubnetMapping
, subnetMapping
, smAllocationId
, smSubnetId
, Tag
, tag
, tagValue
, tagKey
, TagDescription
, tagDescription
, tdResourceARN
, tdTags
, TargetDescription
, targetDescription
, tdAvailabilityZone
, tdPort
, tdId
, TargetGroup
, targetGroup
, tgMatcher
, tgHealthCheckPath
, tgUnhealthyThresholdCount
, tgVPCId
, tgTargetGroupARN
, tgProtocol
, tgHealthCheckIntervalSeconds
, tgTargetType
, tgHealthyThresholdCount
, tgHealthCheckProtocol
, tgLoadBalancerARNs
, tgHealthCheckTimeoutSeconds
, tgHealthCheckPort
, tgTargetGroupName
, tgPort
, TargetGroupAttribute
, targetGroupAttribute
, tgaValue
, tgaKey
, TargetHealth
, targetHealth
, thState
, thReason
, thDescription
, TargetHealthDescription
, targetHealthDescription
, thdTargetHealth
, thdHealthCheckPort
, thdTarget
) where
import Network.AWS.ELBv2.Types.Product
import Network.AWS.ELBv2.Types.Sum
import Network.AWS.Lens
import Network.AWS.Prelude
import Network.AWS.Sign.V4
eLBv2 :: Service
eLBv2 =
Service
{ _svcAbbrev = "ELBv2"
, _svcSigner = v4
, _svcPrefix = "elasticloadbalancing"
, _svcVersion = "2015-12-01"
, _svcEndpoint = defaultEndpoint eLBv2
, _svcTimeout = Just 70
, _svcCheck = statusSuccess
, _svcError = parseXMLError "ELBv2"
, _svcRetry = retry
}
where
retry =
Exponential
{ _retryBase = 5.0e-2
, _retryGrowth = 2
, _retryAttempts = 5
, _retryCheck = check
}
check e
| has (hasCode "ThrottledException" . hasStatus 400) e =
Just "throttled_exception"
| has (hasStatus 429) e = Just "too_many_requests"
| has (hasCode "ThrottlingException" . hasStatus 400) e =
Just "throttling_exception"
| has (hasCode "Throttling" . hasStatus 400) e = Just "throttling"
| has (hasStatus 504) e = Just "gateway_timeout"
| has (hasCode "RequestThrottledException" . hasStatus 400) e =
Just "request_throttled_exception"
| has (hasStatus 502) e = Just "bad_gateway"
| has (hasStatus 503) e = Just "service_unavailable"
| has (hasStatus 500) e = Just "general_server_error"
| has (hasStatus 509) e = Just "limit_exceeded"
| otherwise = Nothing
_InvalidConfigurationRequestException :: AsError a => Getting (First ServiceError) a ServiceError
_InvalidConfigurationRequestException =
_MatchServiceError eLBv2 "InvalidConfigurationRequest" . hasStatus 400
_SubnetNotFoundException :: AsError a => Getting (First ServiceError) a ServiceError
_SubnetNotFoundException =
_MatchServiceError eLBv2 "SubnetNotFound" . hasStatus 400
_TooManyTargetsException :: AsError a => Getting (First ServiceError) a ServiceError
_TooManyTargetsException =
_MatchServiceError eLBv2 "TooManyTargets" . hasStatus 400
_RuleNotFoundException :: AsError a => Getting (First ServiceError) a ServiceError
_RuleNotFoundException = _MatchServiceError eLBv2 "RuleNotFound" . hasStatus 400
_InvalidSubnetException :: AsError a => Getting (First ServiceError) a ServiceError
_InvalidSubnetException =
_MatchServiceError eLBv2 "InvalidSubnet" . hasStatus 400
_TooManyRulesException :: AsError a => Getting (First ServiceError) a ServiceError
_TooManyRulesException = _MatchServiceError eLBv2 "TooManyRules" . hasStatus 400
_TooManyTargetGroupsException :: AsError a => Getting (First ServiceError) a ServiceError
_TooManyTargetGroupsException =
_MatchServiceError eLBv2 "TooManyTargetGroups" . hasStatus 400
_DuplicateLoadBalancerNameException :: AsError a => Getting (First ServiceError) a ServiceError
_DuplicateLoadBalancerNameException =
_MatchServiceError eLBv2 "DuplicateLoadBalancerName" . hasStatus 400
_IncompatibleProtocolsException :: AsError a => Getting (First ServiceError) a ServiceError
_IncompatibleProtocolsException =
_MatchServiceError eLBv2 "IncompatibleProtocols" . hasStatus 400
_TooManyCertificatesException :: AsError a => Getting (First ServiceError) a ServiceError
_TooManyCertificatesException =
_MatchServiceError eLBv2 "TooManyCertificates" . hasStatus 400
_DuplicateTagKeysException :: AsError a => Getting (First ServiceError) a ServiceError
_DuplicateTagKeysException =
_MatchServiceError eLBv2 "DuplicateTagKeys" . hasStatus 400
_DuplicateListenerException :: AsError a => Getting (First ServiceError) a ServiceError
_DuplicateListenerException =
_MatchServiceError eLBv2 "DuplicateListener" . hasStatus 400
_TooManyTagsException :: AsError a => Getting (First ServiceError) a ServiceError
_TooManyTagsException = _MatchServiceError eLBv2 "TooManyTags" . hasStatus 400
_DuplicateTargetGroupNameException :: AsError a => Getting (First ServiceError) a ServiceError
_DuplicateTargetGroupNameException =
_MatchServiceError eLBv2 "DuplicateTargetGroupName" . hasStatus 400
_HealthUnavailableException :: AsError a => Getting (First ServiceError) a ServiceError
_HealthUnavailableException =
_MatchServiceError eLBv2 "HealthUnavailable" . hasStatus 500
_AllocationIdNotFoundException :: AsError a => Getting (First ServiceError) a ServiceError
_AllocationIdNotFoundException =
_MatchServiceError eLBv2 "AllocationIdNotFound" . hasStatus 400
_PriorityInUseException :: AsError a => Getting (First ServiceError) a ServiceError
_PriorityInUseException =
_MatchServiceError eLBv2 "PriorityInUse" . hasStatus 400
_TooManyLoadBalancersException :: AsError a => Getting (First ServiceError) a ServiceError
_TooManyLoadBalancersException =
_MatchServiceError eLBv2 "TooManyLoadBalancers" . hasStatus 400
_UnsupportedProtocolException :: AsError a => Getting (First ServiceError) a ServiceError
_UnsupportedProtocolException =
_MatchServiceError eLBv2 "UnsupportedProtocol" . hasStatus 400
_InvalidTargetException :: AsError a => Getting (First ServiceError) a ServiceError
_InvalidTargetException =
_MatchServiceError eLBv2 "InvalidTarget" . hasStatus 400
_InvalidSecurityGroupException :: AsError a => Getting (First ServiceError) a ServiceError
_InvalidSecurityGroupException =
_MatchServiceError eLBv2 "InvalidSecurityGroup" . hasStatus 400
_TargetGroupNotFoundException :: AsError a => Getting (First ServiceError) a ServiceError
_TargetGroupNotFoundException =
_MatchServiceError eLBv2 "TargetGroupNotFound" . hasStatus 400
_ListenerNotFoundException :: AsError a => Getting (First ServiceError) a ServiceError
_ListenerNotFoundException =
_MatchServiceError eLBv2 "ListenerNotFound" . hasStatus 400
_TooManyRegistrationsForTargetIdException :: AsError a => Getting (First ServiceError) a ServiceError
_TooManyRegistrationsForTargetIdException =
_MatchServiceError eLBv2 "TooManyRegistrationsForTargetId" . hasStatus 400
_TooManyListenersException :: AsError a => Getting (First ServiceError) a ServiceError
_TooManyListenersException =
_MatchServiceError eLBv2 "TooManyListeners" . hasStatus 400
_TargetGroupAssociationLimitException :: AsError a => Getting (First ServiceError) a ServiceError
_TargetGroupAssociationLimitException =
_MatchServiceError eLBv2 "TargetGroupAssociationLimit" . hasStatus 400
_OperationNotPermittedException :: AsError a => Getting (First ServiceError) a ServiceError
_OperationNotPermittedException =
_MatchServiceError eLBv2 "OperationNotPermitted" . hasStatus 400
_SSLPolicyNotFoundException :: AsError a => Getting (First ServiceError) a ServiceError
_SSLPolicyNotFoundException =
_MatchServiceError eLBv2 "SSLPolicyNotFound" . hasStatus 400
_InvalidSchemeException :: AsError a => Getting (First ServiceError) a ServiceError
_InvalidSchemeException =
_MatchServiceError eLBv2 "InvalidScheme" . hasStatus 400
_AvailabilityZoneNotSupportedException :: AsError a => Getting (First ServiceError) a ServiceError
_AvailabilityZoneNotSupportedException =
_MatchServiceError eLBv2 "AvailabilityZoneNotSupported" . hasStatus 400
_LoadBalancerNotFoundException :: AsError a => Getting (First ServiceError) a ServiceError
_LoadBalancerNotFoundException =
_MatchServiceError eLBv2 "LoadBalancerNotFound" . hasStatus 400
_ResourceInUseException :: AsError a => Getting (First ServiceError) a ServiceError
_ResourceInUseException =
_MatchServiceError eLBv2 "ResourceInUse" . hasStatus 400
_CertificateNotFoundException :: AsError a => Getting (First ServiceError) a ServiceError
_CertificateNotFoundException =
_MatchServiceError eLBv2 "CertificateNotFound" . hasStatus 400