{-# LANGUAGE DisambiguateRecordFields #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}
module Amazonka.M2.Types
(
defaultService,
_AccessDeniedException,
_ConflictException,
_InternalServerException,
_ResourceNotFoundException,
_ServiceQuotaExceededException,
_ThrottlingException,
_ValidationException,
ApplicationDeploymentLifecycle (..),
ApplicationLifecycle (..),
ApplicationVersionLifecycle (..),
BatchJobExecutionStatus (..),
BatchJobType (..),
DataSetTaskLifecycle (..),
DeploymentLifecycle (..),
EngineType (..),
EnvironmentLifecycle (..),
AlternateKey (..),
newAlternateKey,
alternateKey_allowDuplicates,
alternateKey_name,
alternateKey_length,
alternateKey_offset,
ApplicationSummary (..),
newApplicationSummary,
applicationSummary_deploymentStatus,
applicationSummary_description,
applicationSummary_environmentId,
applicationSummary_lastStartTime,
applicationSummary_versionStatus,
applicationSummary_applicationArn,
applicationSummary_applicationId,
applicationSummary_applicationVersion,
applicationSummary_creationTime,
applicationSummary_engineType,
applicationSummary_name,
applicationSummary_status,
ApplicationVersionSummary (..),
newApplicationVersionSummary,
applicationVersionSummary_statusReason,
applicationVersionSummary_applicationVersion,
applicationVersionSummary_creationTime,
applicationVersionSummary_status,
BatchJobDefinition (..),
newBatchJobDefinition,
batchJobDefinition_fileBatchJobDefinition,
batchJobDefinition_scriptBatchJobDefinition,
BatchJobExecutionSummary (..),
newBatchJobExecutionSummary,
batchJobExecutionSummary_endTime,
batchJobExecutionSummary_jobId,
batchJobExecutionSummary_jobName,
batchJobExecutionSummary_jobType,
batchJobExecutionSummary_applicationId,
batchJobExecutionSummary_executionId,
batchJobExecutionSummary_startTime,
batchJobExecutionSummary_status,
BatchJobIdentifier (..),
newBatchJobIdentifier,
batchJobIdentifier_fileBatchJobIdentifier,
batchJobIdentifier_scriptBatchJobIdentifier,
DataSet (..),
newDataSet,
dataSet_relativePath,
dataSet_storageType,
dataSet_datasetName,
dataSet_datasetOrg,
dataSet_recordLength,
DataSetImportConfig (..),
newDataSetImportConfig,
dataSetImportConfig_dataSets,
dataSetImportConfig_s3Location,
DataSetImportItem (..),
newDataSetImportItem,
dataSetImportItem_dataSet,
dataSetImportItem_externalLocation,
DataSetImportSummary (..),
newDataSetImportSummary,
dataSetImportSummary_failed,
dataSetImportSummary_inProgress,
dataSetImportSummary_pending,
dataSetImportSummary_succeeded,
dataSetImportSummary_total,
DataSetImportTask (..),
newDataSetImportTask,
dataSetImportTask_status,
dataSetImportTask_summary,
dataSetImportTask_taskId,
DataSetSummary (..),
newDataSetSummary,
dataSetSummary_creationTime,
dataSetSummary_dataSetOrg,
dataSetSummary_format,
dataSetSummary_lastReferencedTime,
dataSetSummary_lastUpdatedTime,
dataSetSummary_dataSetName,
DatasetDetailOrgAttributes (..),
newDatasetDetailOrgAttributes,
datasetDetailOrgAttributes_gdg,
datasetDetailOrgAttributes_vsam,
DatasetOrgAttributes (..),
newDatasetOrgAttributes,
datasetOrgAttributes_gdg,
datasetOrgAttributes_vsam,
Definition (..),
newDefinition,
definition_content,
definition_s3Location,
DeployedVersionSummary (..),
newDeployedVersionSummary,
deployedVersionSummary_statusReason,
deployedVersionSummary_applicationVersion,
deployedVersionSummary_status,
DeploymentSummary (..),
newDeploymentSummary,
deploymentSummary_statusReason,
deploymentSummary_applicationId,
deploymentSummary_applicationVersion,
deploymentSummary_creationTime,
deploymentSummary_deploymentId,
deploymentSummary_environmentId,
deploymentSummary_status,
EfsStorageConfiguration (..),
newEfsStorageConfiguration,
efsStorageConfiguration_fileSystemId,
efsStorageConfiguration_mountPoint,
EngineVersionsSummary (..),
newEngineVersionsSummary,
engineVersionsSummary_engineType,
engineVersionsSummary_engineVersion,
EnvironmentSummary (..),
newEnvironmentSummary,
environmentSummary_creationTime,
environmentSummary_engineType,
environmentSummary_engineVersion,
environmentSummary_environmentArn,
environmentSummary_environmentId,
environmentSummary_instanceType,
environmentSummary_name,
environmentSummary_status,
ExternalLocation (..),
newExternalLocation,
externalLocation_s3Location,
FileBatchJobDefinition (..),
newFileBatchJobDefinition,
fileBatchJobDefinition_folderPath,
fileBatchJobDefinition_fileName,
FileBatchJobIdentifier (..),
newFileBatchJobIdentifier,
fileBatchJobIdentifier_folderPath,
fileBatchJobIdentifier_fileName,
FsxStorageConfiguration (..),
newFsxStorageConfiguration,
fsxStorageConfiguration_fileSystemId,
fsxStorageConfiguration_mountPoint,
GdgAttributes (..),
newGdgAttributes,
gdgAttributes_limit,
gdgAttributes_rollDisposition,
GdgDetailAttributes (..),
newGdgDetailAttributes,
gdgDetailAttributes_limit,
gdgDetailAttributes_rollDisposition,
HighAvailabilityConfig (..),
newHighAvailabilityConfig,
highAvailabilityConfig_desiredCapacity,
LogGroupSummary (..),
newLogGroupSummary,
logGroupSummary_logGroupName,
logGroupSummary_logType,
MaintenanceSchedule (..),
newMaintenanceSchedule,
maintenanceSchedule_endTime,
maintenanceSchedule_startTime,
PendingMaintenance (..),
newPendingMaintenance,
pendingMaintenance_engineVersion,
pendingMaintenance_schedule,
PrimaryKey (..),
newPrimaryKey,
primaryKey_name,
primaryKey_length,
primaryKey_offset,
RecordLength (..),
newRecordLength,
recordLength_max,
recordLength_min,
ScriptBatchJobDefinition (..),
newScriptBatchJobDefinition,
scriptBatchJobDefinition_scriptName,
ScriptBatchJobIdentifier (..),
newScriptBatchJobIdentifier,
scriptBatchJobIdentifier_scriptName,
StorageConfiguration (..),
newStorageConfiguration,
storageConfiguration_efs,
storageConfiguration_fsx,
VsamAttributes (..),
newVsamAttributes,
vsamAttributes_alternateKeys,
vsamAttributes_compressed,
vsamAttributes_encoding,
vsamAttributes_primaryKey,
vsamAttributes_format,
VsamDetailAttributes (..),
newVsamDetailAttributes,
vsamDetailAttributes_alternateKeys,
vsamDetailAttributes_cacheAtStartup,
vsamDetailAttributes_compressed,
vsamDetailAttributes_encoding,
vsamDetailAttributes_primaryKey,
vsamDetailAttributes_recordFormat,
)
where
import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import Amazonka.M2.Types.AlternateKey
import Amazonka.M2.Types.ApplicationDeploymentLifecycle
import Amazonka.M2.Types.ApplicationLifecycle
import Amazonka.M2.Types.ApplicationSummary
import Amazonka.M2.Types.ApplicationVersionLifecycle
import Amazonka.M2.Types.ApplicationVersionSummary
import Amazonka.M2.Types.BatchJobDefinition
import Amazonka.M2.Types.BatchJobExecutionStatus
import Amazonka.M2.Types.BatchJobExecutionSummary
import Amazonka.M2.Types.BatchJobIdentifier
import Amazonka.M2.Types.BatchJobType
import Amazonka.M2.Types.DataSet
import Amazonka.M2.Types.DataSetImportConfig
import Amazonka.M2.Types.DataSetImportItem
import Amazonka.M2.Types.DataSetImportSummary
import Amazonka.M2.Types.DataSetImportTask
import Amazonka.M2.Types.DataSetSummary
import Amazonka.M2.Types.DataSetTaskLifecycle
import Amazonka.M2.Types.DatasetDetailOrgAttributes
import Amazonka.M2.Types.DatasetOrgAttributes
import Amazonka.M2.Types.Definition
import Amazonka.M2.Types.DeployedVersionSummary
import Amazonka.M2.Types.DeploymentLifecycle
import Amazonka.M2.Types.DeploymentSummary
import Amazonka.M2.Types.EfsStorageConfiguration
import Amazonka.M2.Types.EngineType
import Amazonka.M2.Types.EngineVersionsSummary
import Amazonka.M2.Types.EnvironmentLifecycle
import Amazonka.M2.Types.EnvironmentSummary
import Amazonka.M2.Types.ExternalLocation
import Amazonka.M2.Types.FileBatchJobDefinition
import Amazonka.M2.Types.FileBatchJobIdentifier
import Amazonka.M2.Types.FsxStorageConfiguration
import Amazonka.M2.Types.GdgAttributes
import Amazonka.M2.Types.GdgDetailAttributes
import Amazonka.M2.Types.HighAvailabilityConfig
import Amazonka.M2.Types.LogGroupSummary
import Amazonka.M2.Types.MaintenanceSchedule
import Amazonka.M2.Types.PendingMaintenance
import Amazonka.M2.Types.PrimaryKey
import Amazonka.M2.Types.RecordLength
import Amazonka.M2.Types.ScriptBatchJobDefinition
import Amazonka.M2.Types.ScriptBatchJobIdentifier
import Amazonka.M2.Types.StorageConfiguration
import Amazonka.M2.Types.VsamAttributes
import Amazonka.M2.Types.VsamDetailAttributes
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Sign.V4 as Sign
defaultService :: Core.Service
defaultService :: Service
defaultService =
Core.Service
{ $sel:abbrev:Service :: Abbrev
Core.abbrev = Abbrev
"M2",
$sel:signer:Service :: Signer
Core.signer = Signer
Sign.v4,
$sel:endpointPrefix:Service :: ByteString
Core.endpointPrefix = ByteString
"m2",
$sel:signingName:Service :: ByteString
Core.signingName = ByteString
"m2",
$sel:version:Service :: ByteString
Core.version = ByteString
"2021-04-28",
$sel:s3AddressingStyle:Service :: S3AddressingStyle
Core.s3AddressingStyle = S3AddressingStyle
Core.S3AddressingStyleAuto,
$sel:endpoint:Service :: Region -> Endpoint
Core.endpoint = Service -> Region -> Endpoint
Core.defaultEndpoint Service
defaultService,
$sel:timeout:Service :: Maybe Seconds
Core.timeout = forall a. a -> Maybe a
Prelude.Just Seconds
70,
$sel:check:Service :: Status -> Bool
Core.check = Status -> Bool
Core.statusSuccess,
$sel:error:Service :: Status -> [Header] -> ByteStringLazy -> Error
Core.error = Abbrev -> Status -> [Header] -> ByteStringLazy -> Error
Core.parseJSONError Abbrev
"M2",
$sel:retry:Service :: Retry
Core.retry = Retry
retry
}
where
retry :: Retry
retry =
Core.Exponential
{ $sel:base:Exponential :: Double
Core.base = Double
5.0e-2,
$sel:growth:Exponential :: Int
Core.growth = Int
2,
$sel:attempts:Exponential :: Int
Core.attempts = Int
5,
$sel:check:Exponential :: ServiceError -> Maybe Text
Core.check = forall {a}. IsString a => ServiceError -> Maybe a
check
}
check :: ServiceError -> Maybe a
check ServiceError
e
| forall s a. Getting Any s a -> s -> Bool
Lens.has (forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
502) ServiceError
e =
forall a. a -> Maybe a
Prelude.Just a
"bad_gateway"
| forall s a. Getting Any s a -> s -> Bool
Lens.has (forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
504) ServiceError
e =
forall a. a -> Maybe a
Prelude.Just a
"gateway_timeout"
| forall s a. Getting Any s a -> s -> Bool
Lens.has (forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
500) ServiceError
e =
forall a. a -> Maybe a
Prelude.Just a
"general_server_error"
| forall s a. Getting Any s a -> s -> Bool
Lens.has (forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
509) ServiceError
e =
forall a. a -> Maybe a
Prelude.Just a
"limit_exceeded"
| forall s a. Getting Any s a -> s -> Bool
Lens.has
( forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
ErrorCode -> Optic' p f ServiceError ServiceError
Core.hasCode ErrorCode
"RequestThrottledException"
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
400
)
ServiceError
e =
forall a. a -> Maybe a
Prelude.Just a
"request_throttled_exception"
| forall s a. Getting Any s a -> s -> Bool
Lens.has (forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
503) ServiceError
e =
forall a. a -> Maybe a
Prelude.Just a
"service_unavailable"
| forall s a. Getting Any s a -> s -> Bool
Lens.has
( forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
ErrorCode -> Optic' p f ServiceError ServiceError
Core.hasCode ErrorCode
"ThrottledException"
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
400
)
ServiceError
e =
forall a. a -> Maybe a
Prelude.Just a
"throttled_exception"
| forall s a. Getting Any s a -> s -> Bool
Lens.has
( forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
ErrorCode -> Optic' p f ServiceError ServiceError
Core.hasCode ErrorCode
"Throttling"
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
400
)
ServiceError
e =
forall a. a -> Maybe a
Prelude.Just a
"throttling"
| forall s a. Getting Any s a -> s -> Bool
Lens.has
( forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
ErrorCode -> Optic' p f ServiceError ServiceError
Core.hasCode ErrorCode
"ThrottlingException"
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
400
)
ServiceError
e =
forall a. a -> Maybe a
Prelude.Just a
"throttling_exception"
| forall s a. Getting Any s a -> s -> Bool
Lens.has
( forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
ErrorCode -> Optic' p f ServiceError ServiceError
Core.hasCode
ErrorCode
"ProvisionedThroughputExceededException"
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
400
)
ServiceError
e =
forall a. a -> Maybe a
Prelude.Just a
"throughput_exceeded"
| forall s a. Getting Any s a -> s -> Bool
Lens.has (forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
429) ServiceError
e =
forall a. a -> Maybe a
Prelude.Just a
"too_many_requests"
| Bool
Prelude.otherwise = forall a. Maybe a
Prelude.Nothing
_AccessDeniedException :: (Core.AsError a) => Lens.Fold a Core.ServiceError
_AccessDeniedException :: forall a. AsError a => Fold a ServiceError
_AccessDeniedException =
forall a. AsError a => Service -> ErrorCode -> Fold a ServiceError
Core._MatchServiceError
Service
defaultService
ErrorCode
"AccessDeniedException"
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
403
_ConflictException :: (Core.AsError a) => Lens.Fold a Core.ServiceError
_ConflictException :: forall a. AsError a => Fold a ServiceError
_ConflictException =
forall a. AsError a => Service -> ErrorCode -> Fold a ServiceError
Core._MatchServiceError
Service
defaultService
ErrorCode
"ConflictException"
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
409
_InternalServerException :: (Core.AsError a) => Lens.Fold a Core.ServiceError
_InternalServerException :: forall a. AsError a => Fold a ServiceError
_InternalServerException =
forall a. AsError a => Service -> ErrorCode -> Fold a ServiceError
Core._MatchServiceError
Service
defaultService
ErrorCode
"InternalServerException"
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
500
_ResourceNotFoundException :: (Core.AsError a) => Lens.Fold a Core.ServiceError
_ResourceNotFoundException :: forall a. AsError a => Fold a ServiceError
_ResourceNotFoundException =
forall a. AsError a => Service -> ErrorCode -> Fold a ServiceError
Core._MatchServiceError
Service
defaultService
ErrorCode
"ResourceNotFoundException"
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
404
_ServiceQuotaExceededException :: (Core.AsError a) => Lens.Fold a Core.ServiceError
_ServiceQuotaExceededException :: forall a. AsError a => Fold a ServiceError
_ServiceQuotaExceededException =
forall a. AsError a => Service -> ErrorCode -> Fold a ServiceError
Core._MatchServiceError
Service
defaultService
ErrorCode
"ServiceQuotaExceededException"
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
402
_ThrottlingException :: (Core.AsError a) => Lens.Fold a Core.ServiceError
_ThrottlingException :: forall a. AsError a => Fold a ServiceError
_ThrottlingException =
forall a. AsError a => Service -> ErrorCode -> Fold a ServiceError
Core._MatchServiceError
Service
defaultService
ErrorCode
"ThrottlingException"
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
429
_ValidationException :: (Core.AsError a) => Lens.Fold a Core.ServiceError
_ValidationException :: forall a. AsError a => Fold a ServiceError
_ValidationException =
forall a. AsError a => Service -> ErrorCode -> Fold a ServiceError
Core._MatchServiceError
Service
defaultService
ErrorCode
"ValidationException"
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
400