module Network.AWS.Firehose.Types.Product where
import Network.AWS.Firehose.Types.Sum
import Network.AWS.Lens
import Network.AWS.Prelude
data BufferingHints = BufferingHints'
{ _bhSizeInMBs :: !(Maybe Nat)
, _bhIntervalInSeconds :: !(Maybe Nat)
} deriving (Eq, Read, Show, Data, Typeable, Generic)
bufferingHints
:: BufferingHints
bufferingHints =
BufferingHints' {_bhSizeInMBs = Nothing, _bhIntervalInSeconds = Nothing}
bhSizeInMBs :: Lens' BufferingHints (Maybe Natural)
bhSizeInMBs = lens _bhSizeInMBs (\ s a -> s{_bhSizeInMBs = a}) . mapping _Nat;
bhIntervalInSeconds :: Lens' BufferingHints (Maybe Natural)
bhIntervalInSeconds = lens _bhIntervalInSeconds (\ s a -> s{_bhIntervalInSeconds = a}) . mapping _Nat;
instance FromJSON BufferingHints where
parseJSON
= withObject "BufferingHints"
(\ x ->
BufferingHints' <$>
(x .:? "SizeInMBs") <*> (x .:? "IntervalInSeconds"))
instance Hashable BufferingHints where
instance NFData BufferingHints where
instance ToJSON BufferingHints where
toJSON BufferingHints'{..}
= object
(catMaybes
[("SizeInMBs" .=) <$> _bhSizeInMBs,
("IntervalInSeconds" .=) <$> _bhIntervalInSeconds])
data CloudWatchLoggingOptions = CloudWatchLoggingOptions'
{ _cwloEnabled :: !(Maybe Bool)
, _cwloLogGroupName :: !(Maybe Text)
, _cwloLogStreamName :: !(Maybe Text)
} deriving (Eq, Read, Show, Data, Typeable, Generic)
cloudWatchLoggingOptions
:: CloudWatchLoggingOptions
cloudWatchLoggingOptions =
CloudWatchLoggingOptions'
{ _cwloEnabled = Nothing
, _cwloLogGroupName = Nothing
, _cwloLogStreamName = Nothing
}
cwloEnabled :: Lens' CloudWatchLoggingOptions (Maybe Bool)
cwloEnabled = lens _cwloEnabled (\ s a -> s{_cwloEnabled = a});
cwloLogGroupName :: Lens' CloudWatchLoggingOptions (Maybe Text)
cwloLogGroupName = lens _cwloLogGroupName (\ s a -> s{_cwloLogGroupName = a});
cwloLogStreamName :: Lens' CloudWatchLoggingOptions (Maybe Text)
cwloLogStreamName = lens _cwloLogStreamName (\ s a -> s{_cwloLogStreamName = a});
instance FromJSON CloudWatchLoggingOptions where
parseJSON
= withObject "CloudWatchLoggingOptions"
(\ x ->
CloudWatchLoggingOptions' <$>
(x .:? "Enabled") <*> (x .:? "LogGroupName") <*>
(x .:? "LogStreamName"))
instance Hashable CloudWatchLoggingOptions where
instance NFData CloudWatchLoggingOptions where
instance ToJSON CloudWatchLoggingOptions where
toJSON CloudWatchLoggingOptions'{..}
= object
(catMaybes
[("Enabled" .=) <$> _cwloEnabled,
("LogGroupName" .=) <$> _cwloLogGroupName,
("LogStreamName" .=) <$> _cwloLogStreamName])
data CopyCommand = CopyCommand'
{ _ccCopyOptions :: !(Maybe Text)
, _ccDataTableColumns :: !(Maybe Text)
, _ccDataTableName :: !Text
} deriving (Eq, Read, Show, Data, Typeable, Generic)
copyCommand
:: Text
-> CopyCommand
copyCommand pDataTableName_ =
CopyCommand'
{ _ccCopyOptions = Nothing
, _ccDataTableColumns = Nothing
, _ccDataTableName = pDataTableName_
}
ccCopyOptions :: Lens' CopyCommand (Maybe Text)
ccCopyOptions = lens _ccCopyOptions (\ s a -> s{_ccCopyOptions = a});
ccDataTableColumns :: Lens' CopyCommand (Maybe Text)
ccDataTableColumns = lens _ccDataTableColumns (\ s a -> s{_ccDataTableColumns = a});
ccDataTableName :: Lens' CopyCommand Text
ccDataTableName = lens _ccDataTableName (\ s a -> s{_ccDataTableName = a});
instance FromJSON CopyCommand where
parseJSON
= withObject "CopyCommand"
(\ x ->
CopyCommand' <$>
(x .:? "CopyOptions") <*> (x .:? "DataTableColumns")
<*> (x .: "DataTableName"))
instance Hashable CopyCommand where
instance NFData CopyCommand where
instance ToJSON CopyCommand where
toJSON CopyCommand'{..}
= object
(catMaybes
[("CopyOptions" .=) <$> _ccCopyOptions,
("DataTableColumns" .=) <$> _ccDataTableColumns,
Just ("DataTableName" .= _ccDataTableName)])
data DeliveryStreamDescription = DeliveryStreamDescription'
{ _dsdCreateTimestamp :: !(Maybe POSIX)
, _dsdSource :: !(Maybe SourceDescription)
, _dsdLastUpdateTimestamp :: !(Maybe POSIX)
, _dsdDeliveryStreamName :: !Text
, _dsdDeliveryStreamARN :: !Text
, _dsdDeliveryStreamStatus :: !DeliveryStreamStatus
, _dsdDeliveryStreamType :: !DeliveryStreamType
, _dsdVersionId :: !Text
, _dsdDestinations :: ![DestinationDescription]
, _dsdHasMoreDestinations :: !Bool
} deriving (Eq, Show, Data, Typeable, Generic)
deliveryStreamDescription
:: Text
-> Text
-> DeliveryStreamStatus
-> DeliveryStreamType
-> Text
-> Bool
-> DeliveryStreamDescription
deliveryStreamDescription pDeliveryStreamName_ pDeliveryStreamARN_ pDeliveryStreamStatus_ pDeliveryStreamType_ pVersionId_ pHasMoreDestinations_ =
DeliveryStreamDescription'
{ _dsdCreateTimestamp = Nothing
, _dsdSource = Nothing
, _dsdLastUpdateTimestamp = Nothing
, _dsdDeliveryStreamName = pDeliveryStreamName_
, _dsdDeliveryStreamARN = pDeliveryStreamARN_
, _dsdDeliveryStreamStatus = pDeliveryStreamStatus_
, _dsdDeliveryStreamType = pDeliveryStreamType_
, _dsdVersionId = pVersionId_
, _dsdDestinations = mempty
, _dsdHasMoreDestinations = pHasMoreDestinations_
}
dsdCreateTimestamp :: Lens' DeliveryStreamDescription (Maybe UTCTime)
dsdCreateTimestamp = lens _dsdCreateTimestamp (\ s a -> s{_dsdCreateTimestamp = a}) . mapping _Time;
dsdSource :: Lens' DeliveryStreamDescription (Maybe SourceDescription)
dsdSource = lens _dsdSource (\ s a -> s{_dsdSource = a});
dsdLastUpdateTimestamp :: Lens' DeliveryStreamDescription (Maybe UTCTime)
dsdLastUpdateTimestamp = lens _dsdLastUpdateTimestamp (\ s a -> s{_dsdLastUpdateTimestamp = a}) . mapping _Time;
dsdDeliveryStreamName :: Lens' DeliveryStreamDescription Text
dsdDeliveryStreamName = lens _dsdDeliveryStreamName (\ s a -> s{_dsdDeliveryStreamName = a});
dsdDeliveryStreamARN :: Lens' DeliveryStreamDescription Text
dsdDeliveryStreamARN = lens _dsdDeliveryStreamARN (\ s a -> s{_dsdDeliveryStreamARN = a});
dsdDeliveryStreamStatus :: Lens' DeliveryStreamDescription DeliveryStreamStatus
dsdDeliveryStreamStatus = lens _dsdDeliveryStreamStatus (\ s a -> s{_dsdDeliveryStreamStatus = a});
dsdDeliveryStreamType :: Lens' DeliveryStreamDescription DeliveryStreamType
dsdDeliveryStreamType = lens _dsdDeliveryStreamType (\ s a -> s{_dsdDeliveryStreamType = a});
dsdVersionId :: Lens' DeliveryStreamDescription Text
dsdVersionId = lens _dsdVersionId (\ s a -> s{_dsdVersionId = a});
dsdDestinations :: Lens' DeliveryStreamDescription [DestinationDescription]
dsdDestinations = lens _dsdDestinations (\ s a -> s{_dsdDestinations = a}) . _Coerce;
dsdHasMoreDestinations :: Lens' DeliveryStreamDescription Bool
dsdHasMoreDestinations = lens _dsdHasMoreDestinations (\ s a -> s{_dsdHasMoreDestinations = a});
instance FromJSON DeliveryStreamDescription where
parseJSON
= withObject "DeliveryStreamDescription"
(\ x ->
DeliveryStreamDescription' <$>
(x .:? "CreateTimestamp") <*> (x .:? "Source") <*>
(x .:? "LastUpdateTimestamp")
<*> (x .: "DeliveryStreamName")
<*> (x .: "DeliveryStreamARN")
<*> (x .: "DeliveryStreamStatus")
<*> (x .: "DeliveryStreamType")
<*> (x .: "VersionId")
<*> (x .:? "Destinations" .!= mempty)
<*> (x .: "HasMoreDestinations"))
instance Hashable DeliveryStreamDescription where
instance NFData DeliveryStreamDescription where
data DestinationDescription = DestinationDescription'
{ _ddS3DestinationDescription :: !(Maybe S3DestinationDescription)
, _ddExtendedS3DestinationDescription :: !(Maybe ExtendedS3DestinationDescription)
, _ddElasticsearchDestinationDescription :: !(Maybe ElasticsearchDestinationDescription)
, _ddRedshiftDestinationDescription :: !(Maybe RedshiftDestinationDescription)
, _ddDestinationId :: !Text
} deriving (Eq, Show, Data, Typeable, Generic)
destinationDescription
:: Text
-> DestinationDescription
destinationDescription pDestinationId_ =
DestinationDescription'
{ _ddS3DestinationDescription = Nothing
, _ddExtendedS3DestinationDescription = Nothing
, _ddElasticsearchDestinationDescription = Nothing
, _ddRedshiftDestinationDescription = Nothing
, _ddDestinationId = pDestinationId_
}
ddS3DestinationDescription :: Lens' DestinationDescription (Maybe S3DestinationDescription)
ddS3DestinationDescription = lens _ddS3DestinationDescription (\ s a -> s{_ddS3DestinationDescription = a});
ddExtendedS3DestinationDescription :: Lens' DestinationDescription (Maybe ExtendedS3DestinationDescription)
ddExtendedS3DestinationDescription = lens _ddExtendedS3DestinationDescription (\ s a -> s{_ddExtendedS3DestinationDescription = a});
ddElasticsearchDestinationDescription :: Lens' DestinationDescription (Maybe ElasticsearchDestinationDescription)
ddElasticsearchDestinationDescription = lens _ddElasticsearchDestinationDescription (\ s a -> s{_ddElasticsearchDestinationDescription = a});
ddRedshiftDestinationDescription :: Lens' DestinationDescription (Maybe RedshiftDestinationDescription)
ddRedshiftDestinationDescription = lens _ddRedshiftDestinationDescription (\ s a -> s{_ddRedshiftDestinationDescription = a});
ddDestinationId :: Lens' DestinationDescription Text
ddDestinationId = lens _ddDestinationId (\ s a -> s{_ddDestinationId = a});
instance FromJSON DestinationDescription where
parseJSON
= withObject "DestinationDescription"
(\ x ->
DestinationDescription' <$>
(x .:? "S3DestinationDescription") <*>
(x .:? "ExtendedS3DestinationDescription")
<*> (x .:? "ElasticsearchDestinationDescription")
<*> (x .:? "RedshiftDestinationDescription")
<*> (x .: "DestinationId"))
instance Hashable DestinationDescription where
instance NFData DestinationDescription where
data ElasticsearchBufferingHints = ElasticsearchBufferingHints'
{ _ebhSizeInMBs :: !(Maybe Nat)
, _ebhIntervalInSeconds :: !(Maybe Nat)
} deriving (Eq, Read, Show, Data, Typeable, Generic)
elasticsearchBufferingHints
:: ElasticsearchBufferingHints
elasticsearchBufferingHints =
ElasticsearchBufferingHints'
{_ebhSizeInMBs = Nothing, _ebhIntervalInSeconds = Nothing}
ebhSizeInMBs :: Lens' ElasticsearchBufferingHints (Maybe Natural)
ebhSizeInMBs = lens _ebhSizeInMBs (\ s a -> s{_ebhSizeInMBs = a}) . mapping _Nat;
ebhIntervalInSeconds :: Lens' ElasticsearchBufferingHints (Maybe Natural)
ebhIntervalInSeconds = lens _ebhIntervalInSeconds (\ s a -> s{_ebhIntervalInSeconds = a}) . mapping _Nat;
instance FromJSON ElasticsearchBufferingHints where
parseJSON
= withObject "ElasticsearchBufferingHints"
(\ x ->
ElasticsearchBufferingHints' <$>
(x .:? "SizeInMBs") <*> (x .:? "IntervalInSeconds"))
instance Hashable ElasticsearchBufferingHints where
instance NFData ElasticsearchBufferingHints where
instance ToJSON ElasticsearchBufferingHints where
toJSON ElasticsearchBufferingHints'{..}
= object
(catMaybes
[("SizeInMBs" .=) <$> _ebhSizeInMBs,
("IntervalInSeconds" .=) <$> _ebhIntervalInSeconds])
data ElasticsearchDestinationConfiguration = ElasticsearchDestinationConfiguration'
{ _edcIndexRotationPeriod :: !(Maybe ElasticsearchIndexRotationPeriod)
, _edcS3BackupMode :: !(Maybe ElasticsearchS3BackupMode)
, _edcCloudWatchLoggingOptions :: !(Maybe CloudWatchLoggingOptions)
, _edcBufferingHints :: !(Maybe ElasticsearchBufferingHints)
, _edcRetryOptions :: !(Maybe ElasticsearchRetryOptions)
, _edcProcessingConfiguration :: !(Maybe ProcessingConfiguration)
, _edcRoleARN :: !Text
, _edcDomainARN :: !Text
, _edcIndexName :: !Text
, _edcTypeName :: !Text
, _edcS3Configuration :: !S3DestinationConfiguration
} deriving (Eq, Read, Show, Data, Typeable, Generic)
elasticsearchDestinationConfiguration
:: Text
-> Text
-> Text
-> Text
-> S3DestinationConfiguration
-> ElasticsearchDestinationConfiguration
elasticsearchDestinationConfiguration pRoleARN_ pDomainARN_ pIndexName_ pTypeName_ pS3Configuration_ =
ElasticsearchDestinationConfiguration'
{ _edcIndexRotationPeriod = Nothing
, _edcS3BackupMode = Nothing
, _edcCloudWatchLoggingOptions = Nothing
, _edcBufferingHints = Nothing
, _edcRetryOptions = Nothing
, _edcProcessingConfiguration = Nothing
, _edcRoleARN = pRoleARN_
, _edcDomainARN = pDomainARN_
, _edcIndexName = pIndexName_
, _edcTypeName = pTypeName_
, _edcS3Configuration = pS3Configuration_
}
edcIndexRotationPeriod :: Lens' ElasticsearchDestinationConfiguration (Maybe ElasticsearchIndexRotationPeriod)
edcIndexRotationPeriod = lens _edcIndexRotationPeriod (\ s a -> s{_edcIndexRotationPeriod = a});
edcS3BackupMode :: Lens' ElasticsearchDestinationConfiguration (Maybe ElasticsearchS3BackupMode)
edcS3BackupMode = lens _edcS3BackupMode (\ s a -> s{_edcS3BackupMode = a});
edcCloudWatchLoggingOptions :: Lens' ElasticsearchDestinationConfiguration (Maybe CloudWatchLoggingOptions)
edcCloudWatchLoggingOptions = lens _edcCloudWatchLoggingOptions (\ s a -> s{_edcCloudWatchLoggingOptions = a});
edcBufferingHints :: Lens' ElasticsearchDestinationConfiguration (Maybe ElasticsearchBufferingHints)
edcBufferingHints = lens _edcBufferingHints (\ s a -> s{_edcBufferingHints = a});
edcRetryOptions :: Lens' ElasticsearchDestinationConfiguration (Maybe ElasticsearchRetryOptions)
edcRetryOptions = lens _edcRetryOptions (\ s a -> s{_edcRetryOptions = a});
edcProcessingConfiguration :: Lens' ElasticsearchDestinationConfiguration (Maybe ProcessingConfiguration)
edcProcessingConfiguration = lens _edcProcessingConfiguration (\ s a -> s{_edcProcessingConfiguration = a});
edcRoleARN :: Lens' ElasticsearchDestinationConfiguration Text
edcRoleARN = lens _edcRoleARN (\ s a -> s{_edcRoleARN = a});
edcDomainARN :: Lens' ElasticsearchDestinationConfiguration Text
edcDomainARN = lens _edcDomainARN (\ s a -> s{_edcDomainARN = a});
edcIndexName :: Lens' ElasticsearchDestinationConfiguration Text
edcIndexName = lens _edcIndexName (\ s a -> s{_edcIndexName = a});
edcTypeName :: Lens' ElasticsearchDestinationConfiguration Text
edcTypeName = lens _edcTypeName (\ s a -> s{_edcTypeName = a});
edcS3Configuration :: Lens' ElasticsearchDestinationConfiguration S3DestinationConfiguration
edcS3Configuration = lens _edcS3Configuration (\ s a -> s{_edcS3Configuration = a});
instance Hashable
ElasticsearchDestinationConfiguration
where
instance NFData ElasticsearchDestinationConfiguration
where
instance ToJSON ElasticsearchDestinationConfiguration
where
toJSON ElasticsearchDestinationConfiguration'{..}
= object
(catMaybes
[("IndexRotationPeriod" .=) <$>
_edcIndexRotationPeriod,
("S3BackupMode" .=) <$> _edcS3BackupMode,
("CloudWatchLoggingOptions" .=) <$>
_edcCloudWatchLoggingOptions,
("BufferingHints" .=) <$> _edcBufferingHints,
("RetryOptions" .=) <$> _edcRetryOptions,
("ProcessingConfiguration" .=) <$>
_edcProcessingConfiguration,
Just ("RoleARN" .= _edcRoleARN),
Just ("DomainARN" .= _edcDomainARN),
Just ("IndexName" .= _edcIndexName),
Just ("TypeName" .= _edcTypeName),
Just ("S3Configuration" .= _edcS3Configuration)])
data ElasticsearchDestinationDescription = ElasticsearchDestinationDescription'
{ _eddIndexRotationPeriod :: !(Maybe ElasticsearchIndexRotationPeriod)
, _eddTypeName :: !(Maybe Text)
, _eddS3BackupMode :: !(Maybe ElasticsearchS3BackupMode)
, _eddDomainARN :: !(Maybe Text)
, _eddCloudWatchLoggingOptions :: !(Maybe CloudWatchLoggingOptions)
, _eddS3DestinationDescription :: !(Maybe S3DestinationDescription)
, _eddBufferingHints :: !(Maybe ElasticsearchBufferingHints)
, _eddRetryOptions :: !(Maybe ElasticsearchRetryOptions)
, _eddProcessingConfiguration :: !(Maybe ProcessingConfiguration)
, _eddRoleARN :: !(Maybe Text)
, _eddIndexName :: !(Maybe Text)
} deriving (Eq, Read, Show, Data, Typeable, Generic)
elasticsearchDestinationDescription
:: ElasticsearchDestinationDescription
elasticsearchDestinationDescription =
ElasticsearchDestinationDescription'
{ _eddIndexRotationPeriod = Nothing
, _eddTypeName = Nothing
, _eddS3BackupMode = Nothing
, _eddDomainARN = Nothing
, _eddCloudWatchLoggingOptions = Nothing
, _eddS3DestinationDescription = Nothing
, _eddBufferingHints = Nothing
, _eddRetryOptions = Nothing
, _eddProcessingConfiguration = Nothing
, _eddRoleARN = Nothing
, _eddIndexName = Nothing
}
eddIndexRotationPeriod :: Lens' ElasticsearchDestinationDescription (Maybe ElasticsearchIndexRotationPeriod)
eddIndexRotationPeriod = lens _eddIndexRotationPeriod (\ s a -> s{_eddIndexRotationPeriod = a});
eddTypeName :: Lens' ElasticsearchDestinationDescription (Maybe Text)
eddTypeName = lens _eddTypeName (\ s a -> s{_eddTypeName = a});
eddS3BackupMode :: Lens' ElasticsearchDestinationDescription (Maybe ElasticsearchS3BackupMode)
eddS3BackupMode = lens _eddS3BackupMode (\ s a -> s{_eddS3BackupMode = a});
eddDomainARN :: Lens' ElasticsearchDestinationDescription (Maybe Text)
eddDomainARN = lens _eddDomainARN (\ s a -> s{_eddDomainARN = a});
eddCloudWatchLoggingOptions :: Lens' ElasticsearchDestinationDescription (Maybe CloudWatchLoggingOptions)
eddCloudWatchLoggingOptions = lens _eddCloudWatchLoggingOptions (\ s a -> s{_eddCloudWatchLoggingOptions = a});
eddS3DestinationDescription :: Lens' ElasticsearchDestinationDescription (Maybe S3DestinationDescription)
eddS3DestinationDescription = lens _eddS3DestinationDescription (\ s a -> s{_eddS3DestinationDescription = a});
eddBufferingHints :: Lens' ElasticsearchDestinationDescription (Maybe ElasticsearchBufferingHints)
eddBufferingHints = lens _eddBufferingHints (\ s a -> s{_eddBufferingHints = a});
eddRetryOptions :: Lens' ElasticsearchDestinationDescription (Maybe ElasticsearchRetryOptions)
eddRetryOptions = lens _eddRetryOptions (\ s a -> s{_eddRetryOptions = a});
eddProcessingConfiguration :: Lens' ElasticsearchDestinationDescription (Maybe ProcessingConfiguration)
eddProcessingConfiguration = lens _eddProcessingConfiguration (\ s a -> s{_eddProcessingConfiguration = a});
eddRoleARN :: Lens' ElasticsearchDestinationDescription (Maybe Text)
eddRoleARN = lens _eddRoleARN (\ s a -> s{_eddRoleARN = a});
eddIndexName :: Lens' ElasticsearchDestinationDescription (Maybe Text)
eddIndexName = lens _eddIndexName (\ s a -> s{_eddIndexName = a});
instance FromJSON ElasticsearchDestinationDescription
where
parseJSON
= withObject "ElasticsearchDestinationDescription"
(\ x ->
ElasticsearchDestinationDescription' <$>
(x .:? "IndexRotationPeriod") <*> (x .:? "TypeName")
<*> (x .:? "S3BackupMode")
<*> (x .:? "DomainARN")
<*> (x .:? "CloudWatchLoggingOptions")
<*> (x .:? "S3DestinationDescription")
<*> (x .:? "BufferingHints")
<*> (x .:? "RetryOptions")
<*> (x .:? "ProcessingConfiguration")
<*> (x .:? "RoleARN")
<*> (x .:? "IndexName"))
instance Hashable ElasticsearchDestinationDescription
where
instance NFData ElasticsearchDestinationDescription
where
data ElasticsearchDestinationUpdate = ElasticsearchDestinationUpdate'
{ _eduIndexRotationPeriod :: !(Maybe ElasticsearchIndexRotationPeriod)
, _eduTypeName :: !(Maybe Text)
, _eduDomainARN :: !(Maybe Text)
, _eduCloudWatchLoggingOptions :: !(Maybe CloudWatchLoggingOptions)
, _eduS3Update :: !(Maybe S3DestinationUpdate)
, _eduBufferingHints :: !(Maybe ElasticsearchBufferingHints)
, _eduRetryOptions :: !(Maybe ElasticsearchRetryOptions)
, _eduProcessingConfiguration :: !(Maybe ProcessingConfiguration)
, _eduRoleARN :: !(Maybe Text)
, _eduIndexName :: !(Maybe Text)
} deriving (Eq, Read, Show, Data, Typeable, Generic)
elasticsearchDestinationUpdate
:: ElasticsearchDestinationUpdate
elasticsearchDestinationUpdate =
ElasticsearchDestinationUpdate'
{ _eduIndexRotationPeriod = Nothing
, _eduTypeName = Nothing
, _eduDomainARN = Nothing
, _eduCloudWatchLoggingOptions = Nothing
, _eduS3Update = Nothing
, _eduBufferingHints = Nothing
, _eduRetryOptions = Nothing
, _eduProcessingConfiguration = Nothing
, _eduRoleARN = Nothing
, _eduIndexName = Nothing
}
eduIndexRotationPeriod :: Lens' ElasticsearchDestinationUpdate (Maybe ElasticsearchIndexRotationPeriod)
eduIndexRotationPeriod = lens _eduIndexRotationPeriod (\ s a -> s{_eduIndexRotationPeriod = a});
eduTypeName :: Lens' ElasticsearchDestinationUpdate (Maybe Text)
eduTypeName = lens _eduTypeName (\ s a -> s{_eduTypeName = a});
eduDomainARN :: Lens' ElasticsearchDestinationUpdate (Maybe Text)
eduDomainARN = lens _eduDomainARN (\ s a -> s{_eduDomainARN = a});
eduCloudWatchLoggingOptions :: Lens' ElasticsearchDestinationUpdate (Maybe CloudWatchLoggingOptions)
eduCloudWatchLoggingOptions = lens _eduCloudWatchLoggingOptions (\ s a -> s{_eduCloudWatchLoggingOptions = a});
eduS3Update :: Lens' ElasticsearchDestinationUpdate (Maybe S3DestinationUpdate)
eduS3Update = lens _eduS3Update (\ s a -> s{_eduS3Update = a});
eduBufferingHints :: Lens' ElasticsearchDestinationUpdate (Maybe ElasticsearchBufferingHints)
eduBufferingHints = lens _eduBufferingHints (\ s a -> s{_eduBufferingHints = a});
eduRetryOptions :: Lens' ElasticsearchDestinationUpdate (Maybe ElasticsearchRetryOptions)
eduRetryOptions = lens _eduRetryOptions (\ s a -> s{_eduRetryOptions = a});
eduProcessingConfiguration :: Lens' ElasticsearchDestinationUpdate (Maybe ProcessingConfiguration)
eduProcessingConfiguration = lens _eduProcessingConfiguration (\ s a -> s{_eduProcessingConfiguration = a});
eduRoleARN :: Lens' ElasticsearchDestinationUpdate (Maybe Text)
eduRoleARN = lens _eduRoleARN (\ s a -> s{_eduRoleARN = a});
eduIndexName :: Lens' ElasticsearchDestinationUpdate (Maybe Text)
eduIndexName = lens _eduIndexName (\ s a -> s{_eduIndexName = a});
instance Hashable ElasticsearchDestinationUpdate
where
instance NFData ElasticsearchDestinationUpdate where
instance ToJSON ElasticsearchDestinationUpdate where
toJSON ElasticsearchDestinationUpdate'{..}
= object
(catMaybes
[("IndexRotationPeriod" .=) <$>
_eduIndexRotationPeriod,
("TypeName" .=) <$> _eduTypeName,
("DomainARN" .=) <$> _eduDomainARN,
("CloudWatchLoggingOptions" .=) <$>
_eduCloudWatchLoggingOptions,
("S3Update" .=) <$> _eduS3Update,
("BufferingHints" .=) <$> _eduBufferingHints,
("RetryOptions" .=) <$> _eduRetryOptions,
("ProcessingConfiguration" .=) <$>
_eduProcessingConfiguration,
("RoleARN" .=) <$> _eduRoleARN,
("IndexName" .=) <$> _eduIndexName])
newtype ElasticsearchRetryOptions = ElasticsearchRetryOptions'
{ _eroDurationInSeconds :: Maybe Nat
} deriving (Eq, Read, Show, Data, Typeable, Generic)
elasticsearchRetryOptions
:: ElasticsearchRetryOptions
elasticsearchRetryOptions =
ElasticsearchRetryOptions' {_eroDurationInSeconds = Nothing}
eroDurationInSeconds :: Lens' ElasticsearchRetryOptions (Maybe Natural)
eroDurationInSeconds = lens _eroDurationInSeconds (\ s a -> s{_eroDurationInSeconds = a}) . mapping _Nat;
instance FromJSON ElasticsearchRetryOptions where
parseJSON
= withObject "ElasticsearchRetryOptions"
(\ x ->
ElasticsearchRetryOptions' <$>
(x .:? "DurationInSeconds"))
instance Hashable ElasticsearchRetryOptions where
instance NFData ElasticsearchRetryOptions where
instance ToJSON ElasticsearchRetryOptions where
toJSON ElasticsearchRetryOptions'{..}
= object
(catMaybes
[("DurationInSeconds" .=) <$> _eroDurationInSeconds])
data EncryptionConfiguration = EncryptionConfiguration'
{ _ecNoEncryptionConfig :: !(Maybe NoEncryptionConfig)
, _ecKMSEncryptionConfig :: !(Maybe KMSEncryptionConfig)
} deriving (Eq, Read, Show, Data, Typeable, Generic)
encryptionConfiguration
:: EncryptionConfiguration
encryptionConfiguration =
EncryptionConfiguration'
{_ecNoEncryptionConfig = Nothing, _ecKMSEncryptionConfig = Nothing}
ecNoEncryptionConfig :: Lens' EncryptionConfiguration (Maybe NoEncryptionConfig)
ecNoEncryptionConfig = lens _ecNoEncryptionConfig (\ s a -> s{_ecNoEncryptionConfig = a});
ecKMSEncryptionConfig :: Lens' EncryptionConfiguration (Maybe KMSEncryptionConfig)
ecKMSEncryptionConfig = lens _ecKMSEncryptionConfig (\ s a -> s{_ecKMSEncryptionConfig = a});
instance FromJSON EncryptionConfiguration where
parseJSON
= withObject "EncryptionConfiguration"
(\ x ->
EncryptionConfiguration' <$>
(x .:? "NoEncryptionConfig") <*>
(x .:? "KMSEncryptionConfig"))
instance Hashable EncryptionConfiguration where
instance NFData EncryptionConfiguration where
instance ToJSON EncryptionConfiguration where
toJSON EncryptionConfiguration'{..}
= object
(catMaybes
[("NoEncryptionConfig" .=) <$> _ecNoEncryptionConfig,
("KMSEncryptionConfig" .=) <$>
_ecKMSEncryptionConfig])
data ExtendedS3DestinationConfiguration = ExtendedS3DestinationConfiguration'
{ _esdcS3BackupMode :: !(Maybe S3BackupMode)
, _esdcPrefix :: !(Maybe Text)
, _esdcCloudWatchLoggingOptions :: !(Maybe CloudWatchLoggingOptions)
, _esdcS3BackupConfiguration :: !(Maybe S3DestinationConfiguration)
, _esdcEncryptionConfiguration :: !(Maybe EncryptionConfiguration)
, _esdcCompressionFormat :: !(Maybe CompressionFormat)
, _esdcBufferingHints :: !(Maybe BufferingHints)
, _esdcProcessingConfiguration :: !(Maybe ProcessingConfiguration)
, _esdcRoleARN :: !Text
, _esdcBucketARN :: !Text
} deriving (Eq, Read, Show, Data, Typeable, Generic)
extendedS3DestinationConfiguration
:: Text
-> Text
-> ExtendedS3DestinationConfiguration
extendedS3DestinationConfiguration pRoleARN_ pBucketARN_ =
ExtendedS3DestinationConfiguration'
{ _esdcS3BackupMode = Nothing
, _esdcPrefix = Nothing
, _esdcCloudWatchLoggingOptions = Nothing
, _esdcS3BackupConfiguration = Nothing
, _esdcEncryptionConfiguration = Nothing
, _esdcCompressionFormat = Nothing
, _esdcBufferingHints = Nothing
, _esdcProcessingConfiguration = Nothing
, _esdcRoleARN = pRoleARN_
, _esdcBucketARN = pBucketARN_
}
esdcS3BackupMode :: Lens' ExtendedS3DestinationConfiguration (Maybe S3BackupMode)
esdcS3BackupMode = lens _esdcS3BackupMode (\ s a -> s{_esdcS3BackupMode = a});
esdcPrefix :: Lens' ExtendedS3DestinationConfiguration (Maybe Text)
esdcPrefix = lens _esdcPrefix (\ s a -> s{_esdcPrefix = a});
esdcCloudWatchLoggingOptions :: Lens' ExtendedS3DestinationConfiguration (Maybe CloudWatchLoggingOptions)
esdcCloudWatchLoggingOptions = lens _esdcCloudWatchLoggingOptions (\ s a -> s{_esdcCloudWatchLoggingOptions = a});
esdcS3BackupConfiguration :: Lens' ExtendedS3DestinationConfiguration (Maybe S3DestinationConfiguration)
esdcS3BackupConfiguration = lens _esdcS3BackupConfiguration (\ s a -> s{_esdcS3BackupConfiguration = a});
esdcEncryptionConfiguration :: Lens' ExtendedS3DestinationConfiguration (Maybe EncryptionConfiguration)
esdcEncryptionConfiguration = lens _esdcEncryptionConfiguration (\ s a -> s{_esdcEncryptionConfiguration = a});
esdcCompressionFormat :: Lens' ExtendedS3DestinationConfiguration (Maybe CompressionFormat)
esdcCompressionFormat = lens _esdcCompressionFormat (\ s a -> s{_esdcCompressionFormat = a});
esdcBufferingHints :: Lens' ExtendedS3DestinationConfiguration (Maybe BufferingHints)
esdcBufferingHints = lens _esdcBufferingHints (\ s a -> s{_esdcBufferingHints = a});
esdcProcessingConfiguration :: Lens' ExtendedS3DestinationConfiguration (Maybe ProcessingConfiguration)
esdcProcessingConfiguration = lens _esdcProcessingConfiguration (\ s a -> s{_esdcProcessingConfiguration = a});
esdcRoleARN :: Lens' ExtendedS3DestinationConfiguration Text
esdcRoleARN = lens _esdcRoleARN (\ s a -> s{_esdcRoleARN = a});
esdcBucketARN :: Lens' ExtendedS3DestinationConfiguration Text
esdcBucketARN = lens _esdcBucketARN (\ s a -> s{_esdcBucketARN = a});
instance Hashable ExtendedS3DestinationConfiguration
where
instance NFData ExtendedS3DestinationConfiguration
where
instance ToJSON ExtendedS3DestinationConfiguration
where
toJSON ExtendedS3DestinationConfiguration'{..}
= object
(catMaybes
[("S3BackupMode" .=) <$> _esdcS3BackupMode,
("Prefix" .=) <$> _esdcPrefix,
("CloudWatchLoggingOptions" .=) <$>
_esdcCloudWatchLoggingOptions,
("S3BackupConfiguration" .=) <$>
_esdcS3BackupConfiguration,
("EncryptionConfiguration" .=) <$>
_esdcEncryptionConfiguration,
("CompressionFormat" .=) <$> _esdcCompressionFormat,
("BufferingHints" .=) <$> _esdcBufferingHints,
("ProcessingConfiguration" .=) <$>
_esdcProcessingConfiguration,
Just ("RoleARN" .= _esdcRoleARN),
Just ("BucketARN" .= _esdcBucketARN)])
data ExtendedS3DestinationDescription = ExtendedS3DestinationDescription'
{ _esddS3BackupMode :: !(Maybe S3BackupMode)
, _esddS3BackupDescription :: !(Maybe S3DestinationDescription)
, _esddPrefix :: !(Maybe Text)
, _esddCloudWatchLoggingOptions :: !(Maybe CloudWatchLoggingOptions)
, _esddProcessingConfiguration :: !(Maybe ProcessingConfiguration)
, _esddRoleARN :: !Text
, _esddBucketARN :: !Text
, _esddBufferingHints :: !BufferingHints
, _esddCompressionFormat :: !CompressionFormat
, _esddEncryptionConfiguration :: !EncryptionConfiguration
} deriving (Eq, Read, Show, Data, Typeable, Generic)
extendedS3DestinationDescription
:: Text
-> Text
-> BufferingHints
-> CompressionFormat
-> EncryptionConfiguration
-> ExtendedS3DestinationDescription
extendedS3DestinationDescription pRoleARN_ pBucketARN_ pBufferingHints_ pCompressionFormat_ pEncryptionConfiguration_ =
ExtendedS3DestinationDescription'
{ _esddS3BackupMode = Nothing
, _esddS3BackupDescription = Nothing
, _esddPrefix = Nothing
, _esddCloudWatchLoggingOptions = Nothing
, _esddProcessingConfiguration = Nothing
, _esddRoleARN = pRoleARN_
, _esddBucketARN = pBucketARN_
, _esddBufferingHints = pBufferingHints_
, _esddCompressionFormat = pCompressionFormat_
, _esddEncryptionConfiguration = pEncryptionConfiguration_
}
esddS3BackupMode :: Lens' ExtendedS3DestinationDescription (Maybe S3BackupMode)
esddS3BackupMode = lens _esddS3BackupMode (\ s a -> s{_esddS3BackupMode = a});
esddS3BackupDescription :: Lens' ExtendedS3DestinationDescription (Maybe S3DestinationDescription)
esddS3BackupDescription = lens _esddS3BackupDescription (\ s a -> s{_esddS3BackupDescription = a});
esddPrefix :: Lens' ExtendedS3DestinationDescription (Maybe Text)
esddPrefix = lens _esddPrefix (\ s a -> s{_esddPrefix = a});
esddCloudWatchLoggingOptions :: Lens' ExtendedS3DestinationDescription (Maybe CloudWatchLoggingOptions)
esddCloudWatchLoggingOptions = lens _esddCloudWatchLoggingOptions (\ s a -> s{_esddCloudWatchLoggingOptions = a});
esddProcessingConfiguration :: Lens' ExtendedS3DestinationDescription (Maybe ProcessingConfiguration)
esddProcessingConfiguration = lens _esddProcessingConfiguration (\ s a -> s{_esddProcessingConfiguration = a});
esddRoleARN :: Lens' ExtendedS3DestinationDescription Text
esddRoleARN = lens _esddRoleARN (\ s a -> s{_esddRoleARN = a});
esddBucketARN :: Lens' ExtendedS3DestinationDescription Text
esddBucketARN = lens _esddBucketARN (\ s a -> s{_esddBucketARN = a});
esddBufferingHints :: Lens' ExtendedS3DestinationDescription BufferingHints
esddBufferingHints = lens _esddBufferingHints (\ s a -> s{_esddBufferingHints = a});
esddCompressionFormat :: Lens' ExtendedS3DestinationDescription CompressionFormat
esddCompressionFormat = lens _esddCompressionFormat (\ s a -> s{_esddCompressionFormat = a});
esddEncryptionConfiguration :: Lens' ExtendedS3DestinationDescription EncryptionConfiguration
esddEncryptionConfiguration = lens _esddEncryptionConfiguration (\ s a -> s{_esddEncryptionConfiguration = a});
instance FromJSON ExtendedS3DestinationDescription
where
parseJSON
= withObject "ExtendedS3DestinationDescription"
(\ x ->
ExtendedS3DestinationDescription' <$>
(x .:? "S3BackupMode") <*>
(x .:? "S3BackupDescription")
<*> (x .:? "Prefix")
<*> (x .:? "CloudWatchLoggingOptions")
<*> (x .:? "ProcessingConfiguration")
<*> (x .: "RoleARN")
<*> (x .: "BucketARN")
<*> (x .: "BufferingHints")
<*> (x .: "CompressionFormat")
<*> (x .: "EncryptionConfiguration"))
instance Hashable ExtendedS3DestinationDescription
where
instance NFData ExtendedS3DestinationDescription
where
data ExtendedS3DestinationUpdate = ExtendedS3DestinationUpdate'
{ _esduS3BackupMode :: !(Maybe S3BackupMode)
, _esduPrefix :: !(Maybe Text)
, _esduCloudWatchLoggingOptions :: !(Maybe CloudWatchLoggingOptions)
, _esduS3BackupUpdate :: !(Maybe S3DestinationUpdate)
, _esduEncryptionConfiguration :: !(Maybe EncryptionConfiguration)
, _esduCompressionFormat :: !(Maybe CompressionFormat)
, _esduBufferingHints :: !(Maybe BufferingHints)
, _esduBucketARN :: !(Maybe Text)
, _esduProcessingConfiguration :: !(Maybe ProcessingConfiguration)
, _esduRoleARN :: !(Maybe Text)
} deriving (Eq, Read, Show, Data, Typeable, Generic)
extendedS3DestinationUpdate
:: ExtendedS3DestinationUpdate
extendedS3DestinationUpdate =
ExtendedS3DestinationUpdate'
{ _esduS3BackupMode = Nothing
, _esduPrefix = Nothing
, _esduCloudWatchLoggingOptions = Nothing
, _esduS3BackupUpdate = Nothing
, _esduEncryptionConfiguration = Nothing
, _esduCompressionFormat = Nothing
, _esduBufferingHints = Nothing
, _esduBucketARN = Nothing
, _esduProcessingConfiguration = Nothing
, _esduRoleARN = Nothing
}
esduS3BackupMode :: Lens' ExtendedS3DestinationUpdate (Maybe S3BackupMode)
esduS3BackupMode = lens _esduS3BackupMode (\ s a -> s{_esduS3BackupMode = a});
esduPrefix :: Lens' ExtendedS3DestinationUpdate (Maybe Text)
esduPrefix = lens _esduPrefix (\ s a -> s{_esduPrefix = a});
esduCloudWatchLoggingOptions :: Lens' ExtendedS3DestinationUpdate (Maybe CloudWatchLoggingOptions)
esduCloudWatchLoggingOptions = lens _esduCloudWatchLoggingOptions (\ s a -> s{_esduCloudWatchLoggingOptions = a});
esduS3BackupUpdate :: Lens' ExtendedS3DestinationUpdate (Maybe S3DestinationUpdate)
esduS3BackupUpdate = lens _esduS3BackupUpdate (\ s a -> s{_esduS3BackupUpdate = a});
esduEncryptionConfiguration :: Lens' ExtendedS3DestinationUpdate (Maybe EncryptionConfiguration)
esduEncryptionConfiguration = lens _esduEncryptionConfiguration (\ s a -> s{_esduEncryptionConfiguration = a});
esduCompressionFormat :: Lens' ExtendedS3DestinationUpdate (Maybe CompressionFormat)
esduCompressionFormat = lens _esduCompressionFormat (\ s a -> s{_esduCompressionFormat = a});
esduBufferingHints :: Lens' ExtendedS3DestinationUpdate (Maybe BufferingHints)
esduBufferingHints = lens _esduBufferingHints (\ s a -> s{_esduBufferingHints = a});
esduBucketARN :: Lens' ExtendedS3DestinationUpdate (Maybe Text)
esduBucketARN = lens _esduBucketARN (\ s a -> s{_esduBucketARN = a});
esduProcessingConfiguration :: Lens' ExtendedS3DestinationUpdate (Maybe ProcessingConfiguration)
esduProcessingConfiguration = lens _esduProcessingConfiguration (\ s a -> s{_esduProcessingConfiguration = a});
esduRoleARN :: Lens' ExtendedS3DestinationUpdate (Maybe Text)
esduRoleARN = lens _esduRoleARN (\ s a -> s{_esduRoleARN = a});
instance Hashable ExtendedS3DestinationUpdate where
instance NFData ExtendedS3DestinationUpdate where
instance ToJSON ExtendedS3DestinationUpdate where
toJSON ExtendedS3DestinationUpdate'{..}
= object
(catMaybes
[("S3BackupMode" .=) <$> _esduS3BackupMode,
("Prefix" .=) <$> _esduPrefix,
("CloudWatchLoggingOptions" .=) <$>
_esduCloudWatchLoggingOptions,
("S3BackupUpdate" .=) <$> _esduS3BackupUpdate,
("EncryptionConfiguration" .=) <$>
_esduEncryptionConfiguration,
("CompressionFormat" .=) <$> _esduCompressionFormat,
("BufferingHints" .=) <$> _esduBufferingHints,
("BucketARN" .=) <$> _esduBucketARN,
("ProcessingConfiguration" .=) <$>
_esduProcessingConfiguration,
("RoleARN" .=) <$> _esduRoleARN])
newtype KMSEncryptionConfig = KMSEncryptionConfig'
{ _kecAWSKMSKeyARN :: Text
} deriving (Eq, Read, Show, Data, Typeable, Generic)
kmsEncryptionConfig
:: Text
-> KMSEncryptionConfig
kmsEncryptionConfig pAWSKMSKeyARN_ =
KMSEncryptionConfig' {_kecAWSKMSKeyARN = pAWSKMSKeyARN_}
kecAWSKMSKeyARN :: Lens' KMSEncryptionConfig Text
kecAWSKMSKeyARN = lens _kecAWSKMSKeyARN (\ s a -> s{_kecAWSKMSKeyARN = a});
instance FromJSON KMSEncryptionConfig where
parseJSON
= withObject "KMSEncryptionConfig"
(\ x ->
KMSEncryptionConfig' <$> (x .: "AWSKMSKeyARN"))
instance Hashable KMSEncryptionConfig where
instance NFData KMSEncryptionConfig where
instance ToJSON KMSEncryptionConfig where
toJSON KMSEncryptionConfig'{..}
= object
(catMaybes
[Just ("AWSKMSKeyARN" .= _kecAWSKMSKeyARN)])
data KinesisStreamSourceConfiguration = KinesisStreamSourceConfiguration'
{ _ksscKinesisStreamARN :: !Text
, _ksscRoleARN :: !Text
} deriving (Eq, Read, Show, Data, Typeable, Generic)
kinesisStreamSourceConfiguration
:: Text
-> Text
-> KinesisStreamSourceConfiguration
kinesisStreamSourceConfiguration pKinesisStreamARN_ pRoleARN_ =
KinesisStreamSourceConfiguration'
{_ksscKinesisStreamARN = pKinesisStreamARN_, _ksscRoleARN = pRoleARN_}
ksscKinesisStreamARN :: Lens' KinesisStreamSourceConfiguration Text
ksscKinesisStreamARN = lens _ksscKinesisStreamARN (\ s a -> s{_ksscKinesisStreamARN = a});
ksscRoleARN :: Lens' KinesisStreamSourceConfiguration Text
ksscRoleARN = lens _ksscRoleARN (\ s a -> s{_ksscRoleARN = a});
instance Hashable KinesisStreamSourceConfiguration
where
instance NFData KinesisStreamSourceConfiguration
where
instance ToJSON KinesisStreamSourceConfiguration
where
toJSON KinesisStreamSourceConfiguration'{..}
= object
(catMaybes
[Just ("KinesisStreamARN" .= _ksscKinesisStreamARN),
Just ("RoleARN" .= _ksscRoleARN)])
data KinesisStreamSourceDescription = KinesisStreamSourceDescription'
{ _kssdDeliveryStartTimestamp :: !(Maybe POSIX)
, _kssdKinesisStreamARN :: !(Maybe Text)
, _kssdRoleARN :: !(Maybe Text)
} deriving (Eq, Read, Show, Data, Typeable, Generic)
kinesisStreamSourceDescription
:: KinesisStreamSourceDescription
kinesisStreamSourceDescription =
KinesisStreamSourceDescription'
{ _kssdDeliveryStartTimestamp = Nothing
, _kssdKinesisStreamARN = Nothing
, _kssdRoleARN = Nothing
}
kssdDeliveryStartTimestamp :: Lens' KinesisStreamSourceDescription (Maybe UTCTime)
kssdDeliveryStartTimestamp = lens _kssdDeliveryStartTimestamp (\ s a -> s{_kssdDeliveryStartTimestamp = a}) . mapping _Time;
kssdKinesisStreamARN :: Lens' KinesisStreamSourceDescription (Maybe Text)
kssdKinesisStreamARN = lens _kssdKinesisStreamARN (\ s a -> s{_kssdKinesisStreamARN = a});
kssdRoleARN :: Lens' KinesisStreamSourceDescription (Maybe Text)
kssdRoleARN = lens _kssdRoleARN (\ s a -> s{_kssdRoleARN = a});
instance FromJSON KinesisStreamSourceDescription
where
parseJSON
= withObject "KinesisStreamSourceDescription"
(\ x ->
KinesisStreamSourceDescription' <$>
(x .:? "DeliveryStartTimestamp") <*>
(x .:? "KinesisStreamARN")
<*> (x .:? "RoleARN"))
instance Hashable KinesisStreamSourceDescription
where
instance NFData KinesisStreamSourceDescription where
data ProcessingConfiguration = ProcessingConfiguration'
{ _pcEnabled :: !(Maybe Bool)
, _pcProcessors :: !(Maybe [Processor])
} deriving (Eq, Read, Show, Data, Typeable, Generic)
processingConfiguration
:: ProcessingConfiguration
processingConfiguration =
ProcessingConfiguration' {_pcEnabled = Nothing, _pcProcessors = Nothing}
pcEnabled :: Lens' ProcessingConfiguration (Maybe Bool)
pcEnabled = lens _pcEnabled (\ s a -> s{_pcEnabled = a});
pcProcessors :: Lens' ProcessingConfiguration [Processor]
pcProcessors = lens _pcProcessors (\ s a -> s{_pcProcessors = a}) . _Default . _Coerce;
instance FromJSON ProcessingConfiguration where
parseJSON
= withObject "ProcessingConfiguration"
(\ x ->
ProcessingConfiguration' <$>
(x .:? "Enabled") <*>
(x .:? "Processors" .!= mempty))
instance Hashable ProcessingConfiguration where
instance NFData ProcessingConfiguration where
instance ToJSON ProcessingConfiguration where
toJSON ProcessingConfiguration'{..}
= object
(catMaybes
[("Enabled" .=) <$> _pcEnabled,
("Processors" .=) <$> _pcProcessors])
data Processor = Processor'
{ _pParameters :: !(Maybe [ProcessorParameter])
, _pType :: !ProcessorType
} deriving (Eq, Read, Show, Data, Typeable, Generic)
processor
:: ProcessorType
-> Processor
processor pType_ = Processor' {_pParameters = Nothing, _pType = pType_}
pParameters :: Lens' Processor [ProcessorParameter]
pParameters = lens _pParameters (\ s a -> s{_pParameters = a}) . _Default . _Coerce;
pType :: Lens' Processor ProcessorType
pType = lens _pType (\ s a -> s{_pType = a});
instance FromJSON Processor where
parseJSON
= withObject "Processor"
(\ x ->
Processor' <$>
(x .:? "Parameters" .!= mempty) <*> (x .: "Type"))
instance Hashable Processor where
instance NFData Processor where
instance ToJSON Processor where
toJSON Processor'{..}
= object
(catMaybes
[("Parameters" .=) <$> _pParameters,
Just ("Type" .= _pType)])
data ProcessorParameter = ProcessorParameter'
{ _ppParameterName :: !ProcessorParameterName
, _ppParameterValue :: !Text
} deriving (Eq, Read, Show, Data, Typeable, Generic)
processorParameter
:: ProcessorParameterName
-> Text
-> ProcessorParameter
processorParameter pParameterName_ pParameterValue_ =
ProcessorParameter'
{_ppParameterName = pParameterName_, _ppParameterValue = pParameterValue_}
ppParameterName :: Lens' ProcessorParameter ProcessorParameterName
ppParameterName = lens _ppParameterName (\ s a -> s{_ppParameterName = a});
ppParameterValue :: Lens' ProcessorParameter Text
ppParameterValue = lens _ppParameterValue (\ s a -> s{_ppParameterValue = a});
instance FromJSON ProcessorParameter where
parseJSON
= withObject "ProcessorParameter"
(\ x ->
ProcessorParameter' <$>
(x .: "ParameterName") <*> (x .: "ParameterValue"))
instance Hashable ProcessorParameter where
instance NFData ProcessorParameter where
instance ToJSON ProcessorParameter where
toJSON ProcessorParameter'{..}
= object
(catMaybes
[Just ("ParameterName" .= _ppParameterName),
Just ("ParameterValue" .= _ppParameterValue)])
data PutRecordBatchResponseEntry = PutRecordBatchResponseEntry'
{ _prbreRecordId :: !(Maybe Text)
, _prbreErrorCode :: !(Maybe Text)
, _prbreErrorMessage :: !(Maybe Text)
} deriving (Eq, Read, Show, Data, Typeable, Generic)
putRecordBatchResponseEntry
:: PutRecordBatchResponseEntry
putRecordBatchResponseEntry =
PutRecordBatchResponseEntry'
{ _prbreRecordId = Nothing
, _prbreErrorCode = Nothing
, _prbreErrorMessage = Nothing
}
prbreRecordId :: Lens' PutRecordBatchResponseEntry (Maybe Text)
prbreRecordId = lens _prbreRecordId (\ s a -> s{_prbreRecordId = a});
prbreErrorCode :: Lens' PutRecordBatchResponseEntry (Maybe Text)
prbreErrorCode = lens _prbreErrorCode (\ s a -> s{_prbreErrorCode = a});
prbreErrorMessage :: Lens' PutRecordBatchResponseEntry (Maybe Text)
prbreErrorMessage = lens _prbreErrorMessage (\ s a -> s{_prbreErrorMessage = a});
instance FromJSON PutRecordBatchResponseEntry where
parseJSON
= withObject "PutRecordBatchResponseEntry"
(\ x ->
PutRecordBatchResponseEntry' <$>
(x .:? "RecordId") <*> (x .:? "ErrorCode") <*>
(x .:? "ErrorMessage"))
instance Hashable PutRecordBatchResponseEntry where
instance NFData PutRecordBatchResponseEntry where
newtype Record = Record'
{ _rData :: Base64
} deriving (Eq, Read, Show, Data, Typeable, Generic)
record
:: ByteString
-> Record
record pData_ = Record' {_rData = _Base64 # pData_}
rData :: Lens' Record ByteString
rData = lens _rData (\ s a -> s{_rData = a}) . _Base64;
instance Hashable Record where
instance NFData Record where
instance ToJSON Record where
toJSON Record'{..}
= object (catMaybes [Just ("Data" .= _rData)])
data RedshiftDestinationConfiguration = RedshiftDestinationConfiguration'
{ _rdcS3BackupMode :: !(Maybe RedshiftS3BackupMode)
, _rdcCloudWatchLoggingOptions :: !(Maybe CloudWatchLoggingOptions)
, _rdcS3BackupConfiguration :: !(Maybe S3DestinationConfiguration)
, _rdcRetryOptions :: !(Maybe RedshiftRetryOptions)
, _rdcProcessingConfiguration :: !(Maybe ProcessingConfiguration)
, _rdcRoleARN :: !Text
, _rdcClusterJDBCURL :: !Text
, _rdcCopyCommand :: !CopyCommand
, _rdcUsername :: !(Sensitive Text)
, _rdcPassword :: !(Sensitive Text)
, _rdcS3Configuration :: !S3DestinationConfiguration
} deriving (Eq, Show, Data, Typeable, Generic)
redshiftDestinationConfiguration
:: Text
-> Text
-> CopyCommand
-> Text
-> Text
-> S3DestinationConfiguration
-> RedshiftDestinationConfiguration
redshiftDestinationConfiguration pRoleARN_ pClusterJDBCURL_ pCopyCommand_ pUsername_ pPassword_ pS3Configuration_ =
RedshiftDestinationConfiguration'
{ _rdcS3BackupMode = Nothing
, _rdcCloudWatchLoggingOptions = Nothing
, _rdcS3BackupConfiguration = Nothing
, _rdcRetryOptions = Nothing
, _rdcProcessingConfiguration = Nothing
, _rdcRoleARN = pRoleARN_
, _rdcClusterJDBCURL = pClusterJDBCURL_
, _rdcCopyCommand = pCopyCommand_
, _rdcUsername = _Sensitive # pUsername_
, _rdcPassword = _Sensitive # pPassword_
, _rdcS3Configuration = pS3Configuration_
}
rdcS3BackupMode :: Lens' RedshiftDestinationConfiguration (Maybe RedshiftS3BackupMode)
rdcS3BackupMode = lens _rdcS3BackupMode (\ s a -> s{_rdcS3BackupMode = a});
rdcCloudWatchLoggingOptions :: Lens' RedshiftDestinationConfiguration (Maybe CloudWatchLoggingOptions)
rdcCloudWatchLoggingOptions = lens _rdcCloudWatchLoggingOptions (\ s a -> s{_rdcCloudWatchLoggingOptions = a});
rdcS3BackupConfiguration :: Lens' RedshiftDestinationConfiguration (Maybe S3DestinationConfiguration)
rdcS3BackupConfiguration = lens _rdcS3BackupConfiguration (\ s a -> s{_rdcS3BackupConfiguration = a});
rdcRetryOptions :: Lens' RedshiftDestinationConfiguration (Maybe RedshiftRetryOptions)
rdcRetryOptions = lens _rdcRetryOptions (\ s a -> s{_rdcRetryOptions = a});
rdcProcessingConfiguration :: Lens' RedshiftDestinationConfiguration (Maybe ProcessingConfiguration)
rdcProcessingConfiguration = lens _rdcProcessingConfiguration (\ s a -> s{_rdcProcessingConfiguration = a});
rdcRoleARN :: Lens' RedshiftDestinationConfiguration Text
rdcRoleARN = lens _rdcRoleARN (\ s a -> s{_rdcRoleARN = a});
rdcClusterJDBCURL :: Lens' RedshiftDestinationConfiguration Text
rdcClusterJDBCURL = lens _rdcClusterJDBCURL (\ s a -> s{_rdcClusterJDBCURL = a});
rdcCopyCommand :: Lens' RedshiftDestinationConfiguration CopyCommand
rdcCopyCommand = lens _rdcCopyCommand (\ s a -> s{_rdcCopyCommand = a});
rdcUsername :: Lens' RedshiftDestinationConfiguration Text
rdcUsername = lens _rdcUsername (\ s a -> s{_rdcUsername = a}) . _Sensitive;
rdcPassword :: Lens' RedshiftDestinationConfiguration Text
rdcPassword = lens _rdcPassword (\ s a -> s{_rdcPassword = a}) . _Sensitive;
rdcS3Configuration :: Lens' RedshiftDestinationConfiguration S3DestinationConfiguration
rdcS3Configuration = lens _rdcS3Configuration (\ s a -> s{_rdcS3Configuration = a});
instance Hashable RedshiftDestinationConfiguration
where
instance NFData RedshiftDestinationConfiguration
where
instance ToJSON RedshiftDestinationConfiguration
where
toJSON RedshiftDestinationConfiguration'{..}
= object
(catMaybes
[("S3BackupMode" .=) <$> _rdcS3BackupMode,
("CloudWatchLoggingOptions" .=) <$>
_rdcCloudWatchLoggingOptions,
("S3BackupConfiguration" .=) <$>
_rdcS3BackupConfiguration,
("RetryOptions" .=) <$> _rdcRetryOptions,
("ProcessingConfiguration" .=) <$>
_rdcProcessingConfiguration,
Just ("RoleARN" .= _rdcRoleARN),
Just ("ClusterJDBCURL" .= _rdcClusterJDBCURL),
Just ("CopyCommand" .= _rdcCopyCommand),
Just ("Username" .= _rdcUsername),
Just ("Password" .= _rdcPassword),
Just ("S3Configuration" .= _rdcS3Configuration)])
data RedshiftDestinationDescription = RedshiftDestinationDescription'
{ _rddS3BackupMode :: !(Maybe RedshiftS3BackupMode)
, _rddS3BackupDescription :: !(Maybe S3DestinationDescription)
, _rddCloudWatchLoggingOptions :: !(Maybe CloudWatchLoggingOptions)
, _rddRetryOptions :: !(Maybe RedshiftRetryOptions)
, _rddProcessingConfiguration :: !(Maybe ProcessingConfiguration)
, _rddRoleARN :: !Text
, _rddClusterJDBCURL :: !Text
, _rddCopyCommand :: !CopyCommand
, _rddUsername :: !(Sensitive Text)
, _rddS3DestinationDescription :: !S3DestinationDescription
} deriving (Eq, Show, Data, Typeable, Generic)
redshiftDestinationDescription
:: Text
-> Text
-> CopyCommand
-> Text
-> S3DestinationDescription
-> RedshiftDestinationDescription
redshiftDestinationDescription pRoleARN_ pClusterJDBCURL_ pCopyCommand_ pUsername_ pS3DestinationDescription_ =
RedshiftDestinationDescription'
{ _rddS3BackupMode = Nothing
, _rddS3BackupDescription = Nothing
, _rddCloudWatchLoggingOptions = Nothing
, _rddRetryOptions = Nothing
, _rddProcessingConfiguration = Nothing
, _rddRoleARN = pRoleARN_
, _rddClusterJDBCURL = pClusterJDBCURL_
, _rddCopyCommand = pCopyCommand_
, _rddUsername = _Sensitive # pUsername_
, _rddS3DestinationDescription = pS3DestinationDescription_
}
rddS3BackupMode :: Lens' RedshiftDestinationDescription (Maybe RedshiftS3BackupMode)
rddS3BackupMode = lens _rddS3BackupMode (\ s a -> s{_rddS3BackupMode = a});
rddS3BackupDescription :: Lens' RedshiftDestinationDescription (Maybe S3DestinationDescription)
rddS3BackupDescription = lens _rddS3BackupDescription (\ s a -> s{_rddS3BackupDescription = a});
rddCloudWatchLoggingOptions :: Lens' RedshiftDestinationDescription (Maybe CloudWatchLoggingOptions)
rddCloudWatchLoggingOptions = lens _rddCloudWatchLoggingOptions (\ s a -> s{_rddCloudWatchLoggingOptions = a});
rddRetryOptions :: Lens' RedshiftDestinationDescription (Maybe RedshiftRetryOptions)
rddRetryOptions = lens _rddRetryOptions (\ s a -> s{_rddRetryOptions = a});
rddProcessingConfiguration :: Lens' RedshiftDestinationDescription (Maybe ProcessingConfiguration)
rddProcessingConfiguration = lens _rddProcessingConfiguration (\ s a -> s{_rddProcessingConfiguration = a});
rddRoleARN :: Lens' RedshiftDestinationDescription Text
rddRoleARN = lens _rddRoleARN (\ s a -> s{_rddRoleARN = a});
rddClusterJDBCURL :: Lens' RedshiftDestinationDescription Text
rddClusterJDBCURL = lens _rddClusterJDBCURL (\ s a -> s{_rddClusterJDBCURL = a});
rddCopyCommand :: Lens' RedshiftDestinationDescription CopyCommand
rddCopyCommand = lens _rddCopyCommand (\ s a -> s{_rddCopyCommand = a});
rddUsername :: Lens' RedshiftDestinationDescription Text
rddUsername = lens _rddUsername (\ s a -> s{_rddUsername = a}) . _Sensitive;
rddS3DestinationDescription :: Lens' RedshiftDestinationDescription S3DestinationDescription
rddS3DestinationDescription = lens _rddS3DestinationDescription (\ s a -> s{_rddS3DestinationDescription = a});
instance FromJSON RedshiftDestinationDescription
where
parseJSON
= withObject "RedshiftDestinationDescription"
(\ x ->
RedshiftDestinationDescription' <$>
(x .:? "S3BackupMode") <*>
(x .:? "S3BackupDescription")
<*> (x .:? "CloudWatchLoggingOptions")
<*> (x .:? "RetryOptions")
<*> (x .:? "ProcessingConfiguration")
<*> (x .: "RoleARN")
<*> (x .: "ClusterJDBCURL")
<*> (x .: "CopyCommand")
<*> (x .: "Username")
<*> (x .: "S3DestinationDescription"))
instance Hashable RedshiftDestinationDescription
where
instance NFData RedshiftDestinationDescription where
data RedshiftDestinationUpdate = RedshiftDestinationUpdate'
{ _rduS3BackupMode :: !(Maybe RedshiftS3BackupMode)
, _rduCloudWatchLoggingOptions :: !(Maybe CloudWatchLoggingOptions)
, _rduUsername :: !(Maybe (Sensitive Text))
, _rduS3Update :: !(Maybe S3DestinationUpdate)
, _rduPassword :: !(Maybe (Sensitive Text))
, _rduS3BackupUpdate :: !(Maybe S3DestinationUpdate)
, _rduCopyCommand :: !(Maybe CopyCommand)
, _rduRetryOptions :: !(Maybe RedshiftRetryOptions)
, _rduProcessingConfiguration :: !(Maybe ProcessingConfiguration)
, _rduClusterJDBCURL :: !(Maybe Text)
, _rduRoleARN :: !(Maybe Text)
} deriving (Eq, Show, Data, Typeable, Generic)
redshiftDestinationUpdate
:: RedshiftDestinationUpdate
redshiftDestinationUpdate =
RedshiftDestinationUpdate'
{ _rduS3BackupMode = Nothing
, _rduCloudWatchLoggingOptions = Nothing
, _rduUsername = Nothing
, _rduS3Update = Nothing
, _rduPassword = Nothing
, _rduS3BackupUpdate = Nothing
, _rduCopyCommand = Nothing
, _rduRetryOptions = Nothing
, _rduProcessingConfiguration = Nothing
, _rduClusterJDBCURL = Nothing
, _rduRoleARN = Nothing
}
rduS3BackupMode :: Lens' RedshiftDestinationUpdate (Maybe RedshiftS3BackupMode)
rduS3BackupMode = lens _rduS3BackupMode (\ s a -> s{_rduS3BackupMode = a});
rduCloudWatchLoggingOptions :: Lens' RedshiftDestinationUpdate (Maybe CloudWatchLoggingOptions)
rduCloudWatchLoggingOptions = lens _rduCloudWatchLoggingOptions (\ s a -> s{_rduCloudWatchLoggingOptions = a});
rduUsername :: Lens' RedshiftDestinationUpdate (Maybe Text)
rduUsername = lens _rduUsername (\ s a -> s{_rduUsername = a}) . mapping _Sensitive;
rduS3Update :: Lens' RedshiftDestinationUpdate (Maybe S3DestinationUpdate)
rduS3Update = lens _rduS3Update (\ s a -> s{_rduS3Update = a});
rduPassword :: Lens' RedshiftDestinationUpdate (Maybe Text)
rduPassword = lens _rduPassword (\ s a -> s{_rduPassword = a}) . mapping _Sensitive;
rduS3BackupUpdate :: Lens' RedshiftDestinationUpdate (Maybe S3DestinationUpdate)
rduS3BackupUpdate = lens _rduS3BackupUpdate (\ s a -> s{_rduS3BackupUpdate = a});
rduCopyCommand :: Lens' RedshiftDestinationUpdate (Maybe CopyCommand)
rduCopyCommand = lens _rduCopyCommand (\ s a -> s{_rduCopyCommand = a});
rduRetryOptions :: Lens' RedshiftDestinationUpdate (Maybe RedshiftRetryOptions)
rduRetryOptions = lens _rduRetryOptions (\ s a -> s{_rduRetryOptions = a});
rduProcessingConfiguration :: Lens' RedshiftDestinationUpdate (Maybe ProcessingConfiguration)
rduProcessingConfiguration = lens _rduProcessingConfiguration (\ s a -> s{_rduProcessingConfiguration = a});
rduClusterJDBCURL :: Lens' RedshiftDestinationUpdate (Maybe Text)
rduClusterJDBCURL = lens _rduClusterJDBCURL (\ s a -> s{_rduClusterJDBCURL = a});
rduRoleARN :: Lens' RedshiftDestinationUpdate (Maybe Text)
rduRoleARN = lens _rduRoleARN (\ s a -> s{_rduRoleARN = a});
instance Hashable RedshiftDestinationUpdate where
instance NFData RedshiftDestinationUpdate where
instance ToJSON RedshiftDestinationUpdate where
toJSON RedshiftDestinationUpdate'{..}
= object
(catMaybes
[("S3BackupMode" .=) <$> _rduS3BackupMode,
("CloudWatchLoggingOptions" .=) <$>
_rduCloudWatchLoggingOptions,
("Username" .=) <$> _rduUsername,
("S3Update" .=) <$> _rduS3Update,
("Password" .=) <$> _rduPassword,
("S3BackupUpdate" .=) <$> _rduS3BackupUpdate,
("CopyCommand" .=) <$> _rduCopyCommand,
("RetryOptions" .=) <$> _rduRetryOptions,
("ProcessingConfiguration" .=) <$>
_rduProcessingConfiguration,
("ClusterJDBCURL" .=) <$> _rduClusterJDBCURL,
("RoleARN" .=) <$> _rduRoleARN])
newtype RedshiftRetryOptions = RedshiftRetryOptions'
{ _rroDurationInSeconds :: Maybe Nat
} deriving (Eq, Read, Show, Data, Typeable, Generic)
redshiftRetryOptions
:: RedshiftRetryOptions
redshiftRetryOptions = RedshiftRetryOptions' {_rroDurationInSeconds = Nothing}
rroDurationInSeconds :: Lens' RedshiftRetryOptions (Maybe Natural)
rroDurationInSeconds = lens _rroDurationInSeconds (\ s a -> s{_rroDurationInSeconds = a}) . mapping _Nat;
instance FromJSON RedshiftRetryOptions where
parseJSON
= withObject "RedshiftRetryOptions"
(\ x ->
RedshiftRetryOptions' <$>
(x .:? "DurationInSeconds"))
instance Hashable RedshiftRetryOptions where
instance NFData RedshiftRetryOptions where
instance ToJSON RedshiftRetryOptions where
toJSON RedshiftRetryOptions'{..}
= object
(catMaybes
[("DurationInSeconds" .=) <$> _rroDurationInSeconds])
data S3DestinationConfiguration = S3DestinationConfiguration'
{ _sdcPrefix :: !(Maybe Text)
, _sdcCloudWatchLoggingOptions :: !(Maybe CloudWatchLoggingOptions)
, _sdcEncryptionConfiguration :: !(Maybe EncryptionConfiguration)
, _sdcCompressionFormat :: !(Maybe CompressionFormat)
, _sdcBufferingHints :: !(Maybe BufferingHints)
, _sdcRoleARN :: !Text
, _sdcBucketARN :: !Text
} deriving (Eq, Read, Show, Data, Typeable, Generic)
s3DestinationConfiguration
:: Text
-> Text
-> S3DestinationConfiguration
s3DestinationConfiguration pRoleARN_ pBucketARN_ =
S3DestinationConfiguration'
{ _sdcPrefix = Nothing
, _sdcCloudWatchLoggingOptions = Nothing
, _sdcEncryptionConfiguration = Nothing
, _sdcCompressionFormat = Nothing
, _sdcBufferingHints = Nothing
, _sdcRoleARN = pRoleARN_
, _sdcBucketARN = pBucketARN_
}
sdcPrefix :: Lens' S3DestinationConfiguration (Maybe Text)
sdcPrefix = lens _sdcPrefix (\ s a -> s{_sdcPrefix = a});
sdcCloudWatchLoggingOptions :: Lens' S3DestinationConfiguration (Maybe CloudWatchLoggingOptions)
sdcCloudWatchLoggingOptions = lens _sdcCloudWatchLoggingOptions (\ s a -> s{_sdcCloudWatchLoggingOptions = a});
sdcEncryptionConfiguration :: Lens' S3DestinationConfiguration (Maybe EncryptionConfiguration)
sdcEncryptionConfiguration = lens _sdcEncryptionConfiguration (\ s a -> s{_sdcEncryptionConfiguration = a});
sdcCompressionFormat :: Lens' S3DestinationConfiguration (Maybe CompressionFormat)
sdcCompressionFormat = lens _sdcCompressionFormat (\ s a -> s{_sdcCompressionFormat = a});
sdcBufferingHints :: Lens' S3DestinationConfiguration (Maybe BufferingHints)
sdcBufferingHints = lens _sdcBufferingHints (\ s a -> s{_sdcBufferingHints = a});
sdcRoleARN :: Lens' S3DestinationConfiguration Text
sdcRoleARN = lens _sdcRoleARN (\ s a -> s{_sdcRoleARN = a});
sdcBucketARN :: Lens' S3DestinationConfiguration Text
sdcBucketARN = lens _sdcBucketARN (\ s a -> s{_sdcBucketARN = a});
instance Hashable S3DestinationConfiguration where
instance NFData S3DestinationConfiguration where
instance ToJSON S3DestinationConfiguration where
toJSON S3DestinationConfiguration'{..}
= object
(catMaybes
[("Prefix" .=) <$> _sdcPrefix,
("CloudWatchLoggingOptions" .=) <$>
_sdcCloudWatchLoggingOptions,
("EncryptionConfiguration" .=) <$>
_sdcEncryptionConfiguration,
("CompressionFormat" .=) <$> _sdcCompressionFormat,
("BufferingHints" .=) <$> _sdcBufferingHints,
Just ("RoleARN" .= _sdcRoleARN),
Just ("BucketARN" .= _sdcBucketARN)])
data S3DestinationDescription = S3DestinationDescription'
{ _sddPrefix :: !(Maybe Text)
, _sddCloudWatchLoggingOptions :: !(Maybe CloudWatchLoggingOptions)
, _sddRoleARN :: !Text
, _sddBucketARN :: !Text
, _sddBufferingHints :: !BufferingHints
, _sddCompressionFormat :: !CompressionFormat
, _sddEncryptionConfiguration :: !EncryptionConfiguration
} deriving (Eq, Read, Show, Data, Typeable, Generic)
s3DestinationDescription
:: Text
-> Text
-> BufferingHints
-> CompressionFormat
-> EncryptionConfiguration
-> S3DestinationDescription
s3DestinationDescription pRoleARN_ pBucketARN_ pBufferingHints_ pCompressionFormat_ pEncryptionConfiguration_ =
S3DestinationDescription'
{ _sddPrefix = Nothing
, _sddCloudWatchLoggingOptions = Nothing
, _sddRoleARN = pRoleARN_
, _sddBucketARN = pBucketARN_
, _sddBufferingHints = pBufferingHints_
, _sddCompressionFormat = pCompressionFormat_
, _sddEncryptionConfiguration = pEncryptionConfiguration_
}
sddPrefix :: Lens' S3DestinationDescription (Maybe Text)
sddPrefix = lens _sddPrefix (\ s a -> s{_sddPrefix = a});
sddCloudWatchLoggingOptions :: Lens' S3DestinationDescription (Maybe CloudWatchLoggingOptions)
sddCloudWatchLoggingOptions = lens _sddCloudWatchLoggingOptions (\ s a -> s{_sddCloudWatchLoggingOptions = a});
sddRoleARN :: Lens' S3DestinationDescription Text
sddRoleARN = lens _sddRoleARN (\ s a -> s{_sddRoleARN = a});
sddBucketARN :: Lens' S3DestinationDescription Text
sddBucketARN = lens _sddBucketARN (\ s a -> s{_sddBucketARN = a});
sddBufferingHints :: Lens' S3DestinationDescription BufferingHints
sddBufferingHints = lens _sddBufferingHints (\ s a -> s{_sddBufferingHints = a});
sddCompressionFormat :: Lens' S3DestinationDescription CompressionFormat
sddCompressionFormat = lens _sddCompressionFormat (\ s a -> s{_sddCompressionFormat = a});
sddEncryptionConfiguration :: Lens' S3DestinationDescription EncryptionConfiguration
sddEncryptionConfiguration = lens _sddEncryptionConfiguration (\ s a -> s{_sddEncryptionConfiguration = a});
instance FromJSON S3DestinationDescription where
parseJSON
= withObject "S3DestinationDescription"
(\ x ->
S3DestinationDescription' <$>
(x .:? "Prefix") <*>
(x .:? "CloudWatchLoggingOptions")
<*> (x .: "RoleARN")
<*> (x .: "BucketARN")
<*> (x .: "BufferingHints")
<*> (x .: "CompressionFormat")
<*> (x .: "EncryptionConfiguration"))
instance Hashable S3DestinationDescription where
instance NFData S3DestinationDescription where
data S3DestinationUpdate = S3DestinationUpdate'
{ _sduPrefix :: !(Maybe Text)
, _sduCloudWatchLoggingOptions :: !(Maybe CloudWatchLoggingOptions)
, _sduEncryptionConfiguration :: !(Maybe EncryptionConfiguration)
, _sduCompressionFormat :: !(Maybe CompressionFormat)
, _sduBufferingHints :: !(Maybe BufferingHints)
, _sduBucketARN :: !(Maybe Text)
, _sduRoleARN :: !(Maybe Text)
} deriving (Eq, Read, Show, Data, Typeable, Generic)
s3DestinationUpdate
:: S3DestinationUpdate
s3DestinationUpdate =
S3DestinationUpdate'
{ _sduPrefix = Nothing
, _sduCloudWatchLoggingOptions = Nothing
, _sduEncryptionConfiguration = Nothing
, _sduCompressionFormat = Nothing
, _sduBufferingHints = Nothing
, _sduBucketARN = Nothing
, _sduRoleARN = Nothing
}
sduPrefix :: Lens' S3DestinationUpdate (Maybe Text)
sduPrefix = lens _sduPrefix (\ s a -> s{_sduPrefix = a});
sduCloudWatchLoggingOptions :: Lens' S3DestinationUpdate (Maybe CloudWatchLoggingOptions)
sduCloudWatchLoggingOptions = lens _sduCloudWatchLoggingOptions (\ s a -> s{_sduCloudWatchLoggingOptions = a});
sduEncryptionConfiguration :: Lens' S3DestinationUpdate (Maybe EncryptionConfiguration)
sduEncryptionConfiguration = lens _sduEncryptionConfiguration (\ s a -> s{_sduEncryptionConfiguration = a});
sduCompressionFormat :: Lens' S3DestinationUpdate (Maybe CompressionFormat)
sduCompressionFormat = lens _sduCompressionFormat (\ s a -> s{_sduCompressionFormat = a});
sduBufferingHints :: Lens' S3DestinationUpdate (Maybe BufferingHints)
sduBufferingHints = lens _sduBufferingHints (\ s a -> s{_sduBufferingHints = a});
sduBucketARN :: Lens' S3DestinationUpdate (Maybe Text)
sduBucketARN = lens _sduBucketARN (\ s a -> s{_sduBucketARN = a});
sduRoleARN :: Lens' S3DestinationUpdate (Maybe Text)
sduRoleARN = lens _sduRoleARN (\ s a -> s{_sduRoleARN = a});
instance Hashable S3DestinationUpdate where
instance NFData S3DestinationUpdate where
instance ToJSON S3DestinationUpdate where
toJSON S3DestinationUpdate'{..}
= object
(catMaybes
[("Prefix" .=) <$> _sduPrefix,
("CloudWatchLoggingOptions" .=) <$>
_sduCloudWatchLoggingOptions,
("EncryptionConfiguration" .=) <$>
_sduEncryptionConfiguration,
("CompressionFormat" .=) <$> _sduCompressionFormat,
("BufferingHints" .=) <$> _sduBufferingHints,
("BucketARN" .=) <$> _sduBucketARN,
("RoleARN" .=) <$> _sduRoleARN])
data SessionCredentials = SessionCredentials'
{ _scAccessKeyId :: !Text
, _scSecretAccessKey :: !Text
, _scSessionToken :: !Text
, _scExpiration :: !POSIX
} deriving (Eq, Read, Show, Data, Typeable, Generic)
sessionCredentials
:: Text
-> Text
-> Text
-> UTCTime
-> SessionCredentials
sessionCredentials pAccessKeyId_ pSecretAccessKey_ pSessionToken_ pExpiration_ =
SessionCredentials'
{ _scAccessKeyId = pAccessKeyId_
, _scSecretAccessKey = pSecretAccessKey_
, _scSessionToken = pSessionToken_
, _scExpiration = _Time # pExpiration_
}
scAccessKeyId :: Lens' SessionCredentials Text
scAccessKeyId = lens _scAccessKeyId (\ s a -> s{_scAccessKeyId = a});
scSecretAccessKey :: Lens' SessionCredentials Text
scSecretAccessKey = lens _scSecretAccessKey (\ s a -> s{_scSecretAccessKey = a});
scSessionToken :: Lens' SessionCredentials Text
scSessionToken = lens _scSessionToken (\ s a -> s{_scSessionToken = a});
scExpiration :: Lens' SessionCredentials UTCTime
scExpiration = lens _scExpiration (\ s a -> s{_scExpiration = a}) . _Time;
instance FromJSON SessionCredentials where
parseJSON
= withObject "SessionCredentials"
(\ x ->
SessionCredentials' <$>
(x .: "AccessKeyId") <*> (x .: "SecretAccessKey") <*>
(x .: "SessionToken")
<*> (x .: "Expiration"))
instance Hashable SessionCredentials where
instance NFData SessionCredentials where
newtype SourceDescription = SourceDescription'
{ _sdKinesisStreamSourceDescription :: Maybe KinesisStreamSourceDescription
} deriving (Eq, Read, Show, Data, Typeable, Generic)
sourceDescription
:: SourceDescription
sourceDescription =
SourceDescription' {_sdKinesisStreamSourceDescription = Nothing}
sdKinesisStreamSourceDescription :: Lens' SourceDescription (Maybe KinesisStreamSourceDescription)
sdKinesisStreamSourceDescription = lens _sdKinesisStreamSourceDescription (\ s a -> s{_sdKinesisStreamSourceDescription = a});
instance FromJSON SourceDescription where
parseJSON
= withObject "SourceDescription"
(\ x ->
SourceDescription' <$>
(x .:? "KinesisStreamSourceDescription"))
instance Hashable SourceDescription where
instance NFData SourceDescription where