{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
module Network.AWS.AutoScaling.Types.Product where
import Network.AWS.AutoScaling.Types.Sum
import Network.AWS.Lens
import Network.AWS.Prelude
data Activity = Activity'
{ _aProgress :: !(Maybe Int)
, _aStatusMessage :: !(Maybe Text)
, _aEndTime :: !(Maybe ISO8601)
, _aDetails :: !(Maybe Text)
, _aDescription :: !(Maybe Text)
, _aActivityId :: !Text
, _aAutoScalingGroupName :: !Text
, _aCause :: !Text
, _aStartTime :: !ISO8601
, _aStatusCode :: !ScalingActivityStatusCode
} deriving (Eq,Read,Show,Data,Typeable,Generic)
activity
:: Text
-> Text
-> Text
-> UTCTime
-> ScalingActivityStatusCode
-> Activity
activity pActivityId_ pAutoScalingGroupName_ pCause_ pStartTime_ pStatusCode_ =
Activity'
{ _aProgress = Nothing
, _aStatusMessage = Nothing
, _aEndTime = Nothing
, _aDetails = Nothing
, _aDescription = Nothing
, _aActivityId = pActivityId_
, _aAutoScalingGroupName = pAutoScalingGroupName_
, _aCause = pCause_
, _aStartTime = _Time # pStartTime_
, _aStatusCode = pStatusCode_
}
aProgress :: Lens' Activity (Maybe Int)
aProgress = lens _aProgress (\ s a -> s{_aProgress = a});
aStatusMessage :: Lens' Activity (Maybe Text)
aStatusMessage = lens _aStatusMessage (\ s a -> s{_aStatusMessage = a});
aEndTime :: Lens' Activity (Maybe UTCTime)
aEndTime = lens _aEndTime (\ s a -> s{_aEndTime = a}) . mapping _Time;
aDetails :: Lens' Activity (Maybe Text)
aDetails = lens _aDetails (\ s a -> s{_aDetails = a});
aDescription :: Lens' Activity (Maybe Text)
aDescription = lens _aDescription (\ s a -> s{_aDescription = a});
aActivityId :: Lens' Activity Text
aActivityId = lens _aActivityId (\ s a -> s{_aActivityId = a});
aAutoScalingGroupName :: Lens' Activity Text
aAutoScalingGroupName = lens _aAutoScalingGroupName (\ s a -> s{_aAutoScalingGroupName = a});
aCause :: Lens' Activity Text
aCause = lens _aCause (\ s a -> s{_aCause = a});
aStartTime :: Lens' Activity UTCTime
aStartTime = lens _aStartTime (\ s a -> s{_aStartTime = a}) . _Time;
aStatusCode :: Lens' Activity ScalingActivityStatusCode
aStatusCode = lens _aStatusCode (\ s a -> s{_aStatusCode = a});
instance FromXML Activity where
parseXML x
= Activity' <$>
(x .@? "Progress") <*> (x .@? "StatusMessage") <*>
(x .@? "EndTime")
<*> (x .@? "Details")
<*> (x .@? "Description")
<*> (x .@ "ActivityId")
<*> (x .@ "AutoScalingGroupName")
<*> (x .@ "Cause")
<*> (x .@ "StartTime")
<*> (x .@ "StatusCode")
instance Hashable Activity
instance NFData Activity
newtype AdjustmentType = AdjustmentType'
{ _atAdjustmentType :: Maybe Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
adjustmentType
:: AdjustmentType
adjustmentType =
AdjustmentType'
{ _atAdjustmentType = Nothing
}
atAdjustmentType :: Lens' AdjustmentType (Maybe Text)
atAdjustmentType = lens _atAdjustmentType (\ s a -> s{_atAdjustmentType = a});
instance FromXML AdjustmentType where
parseXML x
= AdjustmentType' <$> (x .@? "AdjustmentType")
instance Hashable AdjustmentType
instance NFData AdjustmentType
data Alarm = Alarm'
{ _aAlarmName :: !(Maybe Text)
, _aAlarmARN :: !(Maybe Text)
} deriving (Eq,Read,Show,Data,Typeable,Generic)
alarm
:: Alarm
alarm =
Alarm'
{ _aAlarmName = Nothing
, _aAlarmARN = Nothing
}
aAlarmName :: Lens' Alarm (Maybe Text)
aAlarmName = lens _aAlarmName (\ s a -> s{_aAlarmName = a});
aAlarmARN :: Lens' Alarm (Maybe Text)
aAlarmARN = lens _aAlarmARN (\ s a -> s{_aAlarmARN = a});
instance FromXML Alarm where
parseXML x
= Alarm' <$>
(x .@? "AlarmName") <*> (x .@? "AlarmARN")
instance Hashable Alarm
instance NFData Alarm
data AutoScalingGroup = AutoScalingGroup'
{ _asgStatus :: !(Maybe Text)
, _asgTerminationPolicies :: !(Maybe [Text])
, _asgHealthCheckGracePeriod :: !(Maybe Int)
, _asgNewInstancesProtectedFromScaleIn :: !(Maybe Bool)
, _asgVPCZoneIdentifier :: !(Maybe Text)
, _asgTargetGroupARNs :: !(Maybe [Text])
, _asgEnabledMetrics :: !(Maybe [EnabledMetric])
, _asgLaunchConfigurationName :: !(Maybe Text)
, _asgInstances :: !(Maybe [Instance])
, _asgAutoScalingGroupARN :: !(Maybe Text)
, _asgPlacementGroup :: !(Maybe Text)
, _asgSuspendedProcesses :: !(Maybe [SuspendedProcess])
, _asgLoadBalancerNames :: !(Maybe [Text])
, _asgTags :: !(Maybe [TagDescription])
, _asgAutoScalingGroupName :: !Text
, _asgMinSize :: !Int
, _asgMaxSize :: !Int
, _asgDesiredCapacity :: !Int
, _asgDefaultCooldown :: !Int
, _asgAvailabilityZones :: !(List1 Text)
, _asgHealthCheckType :: !Text
, _asgCreatedTime :: !ISO8601
} deriving (Eq,Read,Show,Data,Typeable,Generic)
autoScalingGroup
:: Text
-> Int
-> Int
-> Int
-> Int
-> NonEmpty Text
-> Text
-> UTCTime
-> AutoScalingGroup
autoScalingGroup pAutoScalingGroupName_ pMinSize_ pMaxSize_ pDesiredCapacity_ pDefaultCooldown_ pAvailabilityZones_ pHealthCheckType_ pCreatedTime_ =
AutoScalingGroup'
{ _asgStatus = Nothing
, _asgTerminationPolicies = Nothing
, _asgHealthCheckGracePeriod = Nothing
, _asgNewInstancesProtectedFromScaleIn = Nothing
, _asgVPCZoneIdentifier = Nothing
, _asgTargetGroupARNs = Nothing
, _asgEnabledMetrics = Nothing
, _asgLaunchConfigurationName = Nothing
, _asgInstances = Nothing
, _asgAutoScalingGroupARN = Nothing
, _asgPlacementGroup = Nothing
, _asgSuspendedProcesses = Nothing
, _asgLoadBalancerNames = Nothing
, _asgTags = Nothing
, _asgAutoScalingGroupName = pAutoScalingGroupName_
, _asgMinSize = pMinSize_
, _asgMaxSize = pMaxSize_
, _asgDesiredCapacity = pDesiredCapacity_
, _asgDefaultCooldown = pDefaultCooldown_
, _asgAvailabilityZones = _List1 # pAvailabilityZones_
, _asgHealthCheckType = pHealthCheckType_
, _asgCreatedTime = _Time # pCreatedTime_
}
asgStatus :: Lens' AutoScalingGroup (Maybe Text)
asgStatus = lens _asgStatus (\ s a -> s{_asgStatus = a});
asgTerminationPolicies :: Lens' AutoScalingGroup [Text]
asgTerminationPolicies = lens _asgTerminationPolicies (\ s a -> s{_asgTerminationPolicies = a}) . _Default . _Coerce;
asgHealthCheckGracePeriod :: Lens' AutoScalingGroup (Maybe Int)
asgHealthCheckGracePeriod = lens _asgHealthCheckGracePeriod (\ s a -> s{_asgHealthCheckGracePeriod = a});
asgNewInstancesProtectedFromScaleIn :: Lens' AutoScalingGroup (Maybe Bool)
asgNewInstancesProtectedFromScaleIn = lens _asgNewInstancesProtectedFromScaleIn (\ s a -> s{_asgNewInstancesProtectedFromScaleIn = a});
asgVPCZoneIdentifier :: Lens' AutoScalingGroup (Maybe Text)
asgVPCZoneIdentifier = lens _asgVPCZoneIdentifier (\ s a -> s{_asgVPCZoneIdentifier = a});
asgTargetGroupARNs :: Lens' AutoScalingGroup [Text]
asgTargetGroupARNs = lens _asgTargetGroupARNs (\ s a -> s{_asgTargetGroupARNs = a}) . _Default . _Coerce;
asgEnabledMetrics :: Lens' AutoScalingGroup [EnabledMetric]
asgEnabledMetrics = lens _asgEnabledMetrics (\ s a -> s{_asgEnabledMetrics = a}) . _Default . _Coerce;
asgLaunchConfigurationName :: Lens' AutoScalingGroup (Maybe Text)
asgLaunchConfigurationName = lens _asgLaunchConfigurationName (\ s a -> s{_asgLaunchConfigurationName = a});
asgInstances :: Lens' AutoScalingGroup [Instance]
asgInstances = lens _asgInstances (\ s a -> s{_asgInstances = a}) . _Default . _Coerce;
asgAutoScalingGroupARN :: Lens' AutoScalingGroup (Maybe Text)
asgAutoScalingGroupARN = lens _asgAutoScalingGroupARN (\ s a -> s{_asgAutoScalingGroupARN = a});
asgPlacementGroup :: Lens' AutoScalingGroup (Maybe Text)
asgPlacementGroup = lens _asgPlacementGroup (\ s a -> s{_asgPlacementGroup = a});
asgSuspendedProcesses :: Lens' AutoScalingGroup [SuspendedProcess]
asgSuspendedProcesses = lens _asgSuspendedProcesses (\ s a -> s{_asgSuspendedProcesses = a}) . _Default . _Coerce;
asgLoadBalancerNames :: Lens' AutoScalingGroup [Text]
asgLoadBalancerNames = lens _asgLoadBalancerNames (\ s a -> s{_asgLoadBalancerNames = a}) . _Default . _Coerce;
asgTags :: Lens' AutoScalingGroup [TagDescription]
asgTags = lens _asgTags (\ s a -> s{_asgTags = a}) . _Default . _Coerce;
asgAutoScalingGroupName :: Lens' AutoScalingGroup Text
asgAutoScalingGroupName = lens _asgAutoScalingGroupName (\ s a -> s{_asgAutoScalingGroupName = a});
asgMinSize :: Lens' AutoScalingGroup Int
asgMinSize = lens _asgMinSize (\ s a -> s{_asgMinSize = a});
asgMaxSize :: Lens' AutoScalingGroup Int
asgMaxSize = lens _asgMaxSize (\ s a -> s{_asgMaxSize = a});
asgDesiredCapacity :: Lens' AutoScalingGroup Int
asgDesiredCapacity = lens _asgDesiredCapacity (\ s a -> s{_asgDesiredCapacity = a});
asgDefaultCooldown :: Lens' AutoScalingGroup Int
asgDefaultCooldown = lens _asgDefaultCooldown (\ s a -> s{_asgDefaultCooldown = a});
asgAvailabilityZones :: Lens' AutoScalingGroup (NonEmpty Text)
asgAvailabilityZones = lens _asgAvailabilityZones (\ s a -> s{_asgAvailabilityZones = a}) . _List1;
asgHealthCheckType :: Lens' AutoScalingGroup Text
asgHealthCheckType = lens _asgHealthCheckType (\ s a -> s{_asgHealthCheckType = a});
asgCreatedTime :: Lens' AutoScalingGroup UTCTime
asgCreatedTime = lens _asgCreatedTime (\ s a -> s{_asgCreatedTime = a}) . _Time;
instance FromXML AutoScalingGroup where
parseXML x
= AutoScalingGroup' <$>
(x .@? "Status") <*>
(x .@? "TerminationPolicies" .!@ mempty >>=
may (parseXMLList "member"))
<*> (x .@? "HealthCheckGracePeriod")
<*> (x .@? "NewInstancesProtectedFromScaleIn")
<*> (x .@? "VPCZoneIdentifier")
<*>
(x .@? "TargetGroupARNs" .!@ mempty >>=
may (parseXMLList "member"))
<*>
(x .@? "EnabledMetrics" .!@ mempty >>=
may (parseXMLList "member"))
<*> (x .@? "LaunchConfigurationName")
<*>
(x .@? "Instances" .!@ mempty >>=
may (parseXMLList "member"))
<*> (x .@? "AutoScalingGroupARN")
<*> (x .@? "PlacementGroup")
<*>
(x .@? "SuspendedProcesses" .!@ mempty >>=
may (parseXMLList "member"))
<*>
(x .@? "LoadBalancerNames" .!@ mempty >>=
may (parseXMLList "member"))
<*>
(x .@? "Tags" .!@ mempty >>=
may (parseXMLList "member"))
<*> (x .@ "AutoScalingGroupName")
<*> (x .@ "MinSize")
<*> (x .@ "MaxSize")
<*> (x .@ "DesiredCapacity")
<*> (x .@ "DefaultCooldown")
<*>
(x .@? "AvailabilityZones" .!@ mempty >>=
parseXMLList1 "member")
<*> (x .@ "HealthCheckType")
<*> (x .@ "CreatedTime")
instance Hashable AutoScalingGroup
instance NFData AutoScalingGroup
data AutoScalingInstanceDetails = AutoScalingInstanceDetails'
{ _asidLaunchConfigurationName :: !(Maybe Text)
, _asidInstanceId :: !Text
, _asidAutoScalingGroupName :: !Text
, _asidAvailabilityZone :: !Text
, _asidLifecycleState :: !Text
, _asidHealthStatus :: !Text
, _asidProtectedFromScaleIn :: !Bool
} deriving (Eq,Read,Show,Data,Typeable,Generic)
autoScalingInstanceDetails
:: Text
-> Text
-> Text
-> Text
-> Text
-> Bool
-> AutoScalingInstanceDetails
autoScalingInstanceDetails pInstanceId_ pAutoScalingGroupName_ pAvailabilityZone_ pLifecycleState_ pHealthStatus_ pProtectedFromScaleIn_ =
AutoScalingInstanceDetails'
{ _asidLaunchConfigurationName = Nothing
, _asidInstanceId = pInstanceId_
, _asidAutoScalingGroupName = pAutoScalingGroupName_
, _asidAvailabilityZone = pAvailabilityZone_
, _asidLifecycleState = pLifecycleState_
, _asidHealthStatus = pHealthStatus_
, _asidProtectedFromScaleIn = pProtectedFromScaleIn_
}
asidLaunchConfigurationName :: Lens' AutoScalingInstanceDetails (Maybe Text)
asidLaunchConfigurationName = lens _asidLaunchConfigurationName (\ s a -> s{_asidLaunchConfigurationName = a});
asidInstanceId :: Lens' AutoScalingInstanceDetails Text
asidInstanceId = lens _asidInstanceId (\ s a -> s{_asidInstanceId = a});
asidAutoScalingGroupName :: Lens' AutoScalingInstanceDetails Text
asidAutoScalingGroupName = lens _asidAutoScalingGroupName (\ s a -> s{_asidAutoScalingGroupName = a});
asidAvailabilityZone :: Lens' AutoScalingInstanceDetails Text
asidAvailabilityZone = lens _asidAvailabilityZone (\ s a -> s{_asidAvailabilityZone = a});
asidLifecycleState :: Lens' AutoScalingInstanceDetails Text
asidLifecycleState = lens _asidLifecycleState (\ s a -> s{_asidLifecycleState = a});
asidHealthStatus :: Lens' AutoScalingInstanceDetails Text
asidHealthStatus = lens _asidHealthStatus (\ s a -> s{_asidHealthStatus = a});
asidProtectedFromScaleIn :: Lens' AutoScalingInstanceDetails Bool
asidProtectedFromScaleIn = lens _asidProtectedFromScaleIn (\ s a -> s{_asidProtectedFromScaleIn = a});
instance FromXML AutoScalingInstanceDetails where
parseXML x
= AutoScalingInstanceDetails' <$>
(x .@? "LaunchConfigurationName") <*>
(x .@ "InstanceId")
<*> (x .@ "AutoScalingGroupName")
<*> (x .@ "AvailabilityZone")
<*> (x .@ "LifecycleState")
<*> (x .@ "HealthStatus")
<*> (x .@ "ProtectedFromScaleIn")
instance Hashable AutoScalingInstanceDetails
instance NFData AutoScalingInstanceDetails
data BlockDeviceMapping = BlockDeviceMapping'
{ _bdmVirtualName :: !(Maybe Text)
, _bdmNoDevice :: !(Maybe Bool)
, _bdmEBS :: !(Maybe EBS)
, _bdmDeviceName :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
blockDeviceMapping
:: Text
-> BlockDeviceMapping
blockDeviceMapping pDeviceName_ =
BlockDeviceMapping'
{ _bdmVirtualName = Nothing
, _bdmNoDevice = Nothing
, _bdmEBS = Nothing
, _bdmDeviceName = pDeviceName_
}
bdmVirtualName :: Lens' BlockDeviceMapping (Maybe Text)
bdmVirtualName = lens _bdmVirtualName (\ s a -> s{_bdmVirtualName = a});
bdmNoDevice :: Lens' BlockDeviceMapping (Maybe Bool)
bdmNoDevice = lens _bdmNoDevice (\ s a -> s{_bdmNoDevice = a});
bdmEBS :: Lens' BlockDeviceMapping (Maybe EBS)
bdmEBS = lens _bdmEBS (\ s a -> s{_bdmEBS = a});
bdmDeviceName :: Lens' BlockDeviceMapping Text
bdmDeviceName = lens _bdmDeviceName (\ s a -> s{_bdmDeviceName = a});
instance FromXML BlockDeviceMapping where
parseXML x
= BlockDeviceMapping' <$>
(x .@? "VirtualName") <*> (x .@? "NoDevice") <*>
(x .@? "Ebs")
<*> (x .@ "DeviceName")
instance Hashable BlockDeviceMapping
instance NFData BlockDeviceMapping
instance ToQuery BlockDeviceMapping where
toQuery BlockDeviceMapping'{..}
= mconcat
["VirtualName" =: _bdmVirtualName,
"NoDevice" =: _bdmNoDevice, "Ebs" =: _bdmEBS,
"DeviceName" =: _bdmDeviceName]
data EBS = EBS'
{ _ebsDeleteOnTermination :: !(Maybe Bool)
, _ebsVolumeSize :: !(Maybe Nat)
, _ebsIOPS :: !(Maybe Nat)
, _ebsEncrypted :: !(Maybe Bool)
, _ebsVolumeType :: !(Maybe Text)
, _ebsSnapshotId :: !(Maybe Text)
} deriving (Eq,Read,Show,Data,Typeable,Generic)
ebs
:: EBS
ebs =
EBS'
{ _ebsDeleteOnTermination = Nothing
, _ebsVolumeSize = Nothing
, _ebsIOPS = Nothing
, _ebsEncrypted = Nothing
, _ebsVolumeType = Nothing
, _ebsSnapshotId = Nothing
}
ebsDeleteOnTermination :: Lens' EBS (Maybe Bool)
ebsDeleteOnTermination = lens _ebsDeleteOnTermination (\ s a -> s{_ebsDeleteOnTermination = a});
ebsVolumeSize :: Lens' EBS (Maybe Natural)
ebsVolumeSize = lens _ebsVolumeSize (\ s a -> s{_ebsVolumeSize = a}) . mapping _Nat;
ebsIOPS :: Lens' EBS (Maybe Natural)
ebsIOPS = lens _ebsIOPS (\ s a -> s{_ebsIOPS = a}) . mapping _Nat;
ebsEncrypted :: Lens' EBS (Maybe Bool)
ebsEncrypted = lens _ebsEncrypted (\ s a -> s{_ebsEncrypted = a});
ebsVolumeType :: Lens' EBS (Maybe Text)
ebsVolumeType = lens _ebsVolumeType (\ s a -> s{_ebsVolumeType = a});
ebsSnapshotId :: Lens' EBS (Maybe Text)
ebsSnapshotId = lens _ebsSnapshotId (\ s a -> s{_ebsSnapshotId = a});
instance FromXML EBS where
parseXML x
= EBS' <$>
(x .@? "DeleteOnTermination") <*>
(x .@? "VolumeSize")
<*> (x .@? "Iops")
<*> (x .@? "Encrypted")
<*> (x .@? "VolumeType")
<*> (x .@? "SnapshotId")
instance Hashable EBS
instance NFData EBS
instance ToQuery EBS where
toQuery EBS'{..}
= mconcat
["DeleteOnTermination" =: _ebsDeleteOnTermination,
"VolumeSize" =: _ebsVolumeSize, "Iops" =: _ebsIOPS,
"Encrypted" =: _ebsEncrypted,
"VolumeType" =: _ebsVolumeType,
"SnapshotId" =: _ebsSnapshotId]
data EnabledMetric = EnabledMetric'
{ _emGranularity :: !(Maybe Text)
, _emMetric :: !(Maybe Text)
} deriving (Eq,Read,Show,Data,Typeable,Generic)
enabledMetric
:: EnabledMetric
enabledMetric =
EnabledMetric'
{ _emGranularity = Nothing
, _emMetric = Nothing
}
emGranularity :: Lens' EnabledMetric (Maybe Text)
emGranularity = lens _emGranularity (\ s a -> s{_emGranularity = a});
emMetric :: Lens' EnabledMetric (Maybe Text)
emMetric = lens _emMetric (\ s a -> s{_emMetric = a});
instance FromXML EnabledMetric where
parseXML x
= EnabledMetric' <$>
(x .@? "Granularity") <*> (x .@? "Metric")
instance Hashable EnabledMetric
instance NFData EnabledMetric
data Filter = Filter'
{ _fValues :: !(Maybe [Text])
, _fName :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
filter'
:: Text
-> Filter
filter' pName_ =
Filter'
{ _fValues = Nothing
, _fName = pName_
}
fValues :: Lens' Filter [Text]
fValues = lens _fValues (\ s a -> s{_fValues = a}) . _Default . _Coerce;
fName :: Lens' Filter Text
fName = lens _fName (\ s a -> s{_fName = a});
instance Hashable Filter
instance NFData Filter
instance ToQuery Filter where
toQuery Filter'{..}
= mconcat
["Values" =:
toQuery (toQueryList "member" <$> _fValues),
"Name" =: _fName]
data Instance = Instance'
{ _iLaunchConfigurationName :: !(Maybe Text)
, _iInstanceId :: !Text
, _iAvailabilityZone :: !Text
, _iLifecycleState :: !LifecycleState
, _iHealthStatus :: !Text
, _iProtectedFromScaleIn :: !Bool
} deriving (Eq,Read,Show,Data,Typeable,Generic)
instance'
:: Text
-> Text
-> LifecycleState
-> Text
-> Bool
-> Instance
instance' pInstanceId_ pAvailabilityZone_ pLifecycleState_ pHealthStatus_ pProtectedFromScaleIn_ =
Instance'
{ _iLaunchConfigurationName = Nothing
, _iInstanceId = pInstanceId_
, _iAvailabilityZone = pAvailabilityZone_
, _iLifecycleState = pLifecycleState_
, _iHealthStatus = pHealthStatus_
, _iProtectedFromScaleIn = pProtectedFromScaleIn_
}
iLaunchConfigurationName :: Lens' Instance (Maybe Text)
iLaunchConfigurationName = lens _iLaunchConfigurationName (\ s a -> s{_iLaunchConfigurationName = a});
iInstanceId :: Lens' Instance Text
iInstanceId = lens _iInstanceId (\ s a -> s{_iInstanceId = a});
iAvailabilityZone :: Lens' Instance Text
iAvailabilityZone = lens _iAvailabilityZone (\ s a -> s{_iAvailabilityZone = a});
iLifecycleState :: Lens' Instance LifecycleState
iLifecycleState = lens _iLifecycleState (\ s a -> s{_iLifecycleState = a});
iHealthStatus :: Lens' Instance Text
iHealthStatus = lens _iHealthStatus (\ s a -> s{_iHealthStatus = a});
iProtectedFromScaleIn :: Lens' Instance Bool
iProtectedFromScaleIn = lens _iProtectedFromScaleIn (\ s a -> s{_iProtectedFromScaleIn = a});
instance FromXML Instance where
parseXML x
= Instance' <$>
(x .@? "LaunchConfigurationName") <*>
(x .@ "InstanceId")
<*> (x .@ "AvailabilityZone")
<*> (x .@ "LifecycleState")
<*> (x .@ "HealthStatus")
<*> (x .@ "ProtectedFromScaleIn")
instance Hashable Instance
instance NFData Instance
newtype InstanceMonitoring = InstanceMonitoring'
{ _imEnabled :: Maybe Bool
} deriving (Eq,Read,Show,Data,Typeable,Generic)
instanceMonitoring
:: InstanceMonitoring
instanceMonitoring =
InstanceMonitoring'
{ _imEnabled = Nothing
}
imEnabled :: Lens' InstanceMonitoring (Maybe Bool)
imEnabled = lens _imEnabled (\ s a -> s{_imEnabled = a});
instance FromXML InstanceMonitoring where
parseXML x
= InstanceMonitoring' <$> (x .@? "Enabled")
instance Hashable InstanceMonitoring
instance NFData InstanceMonitoring
instance ToQuery InstanceMonitoring where
toQuery InstanceMonitoring'{..}
= mconcat ["Enabled" =: _imEnabled]
data LaunchConfiguration = LaunchConfiguration'
{ _lcAssociatePublicIPAddress :: !(Maybe Bool)
, _lcSecurityGroups :: !(Maybe [Text])
, _lcSpotPrice :: !(Maybe Text)
, _lcInstanceMonitoring :: !(Maybe InstanceMonitoring)
, _lcKeyName :: !(Maybe Text)
, _lcClassicLinkVPCSecurityGroups :: !(Maybe [Text])
, _lcRAMDiskId :: !(Maybe Text)
, _lcKernelId :: !(Maybe Text)
, _lcEBSOptimized :: !(Maybe Bool)
, _lcUserData :: !(Maybe Text)
, _lcClassicLinkVPCId :: !(Maybe Text)
, _lcIAMInstanceProfile :: !(Maybe Text)
, _lcLaunchConfigurationARN :: !(Maybe Text)
, _lcPlacementTenancy :: !(Maybe Text)
, _lcBlockDeviceMappings :: !(Maybe [BlockDeviceMapping])
, _lcLaunchConfigurationName :: !Text
, _lcImageId :: !Text
, _lcInstanceType :: !Text
, _lcCreatedTime :: !ISO8601
} deriving (Eq,Read,Show,Data,Typeable,Generic)
launchConfiguration
:: Text
-> Text
-> Text
-> UTCTime
-> LaunchConfiguration
launchConfiguration pLaunchConfigurationName_ pImageId_ pInstanceType_ pCreatedTime_ =
LaunchConfiguration'
{ _lcAssociatePublicIPAddress = Nothing
, _lcSecurityGroups = Nothing
, _lcSpotPrice = Nothing
, _lcInstanceMonitoring = Nothing
, _lcKeyName = Nothing
, _lcClassicLinkVPCSecurityGroups = Nothing
, _lcRAMDiskId = Nothing
, _lcKernelId = Nothing
, _lcEBSOptimized = Nothing
, _lcUserData = Nothing
, _lcClassicLinkVPCId = Nothing
, _lcIAMInstanceProfile = Nothing
, _lcLaunchConfigurationARN = Nothing
, _lcPlacementTenancy = Nothing
, _lcBlockDeviceMappings = Nothing
, _lcLaunchConfigurationName = pLaunchConfigurationName_
, _lcImageId = pImageId_
, _lcInstanceType = pInstanceType_
, _lcCreatedTime = _Time # pCreatedTime_
}
lcAssociatePublicIPAddress :: Lens' LaunchConfiguration (Maybe Bool)
lcAssociatePublicIPAddress = lens _lcAssociatePublicIPAddress (\ s a -> s{_lcAssociatePublicIPAddress = a});
lcSecurityGroups :: Lens' LaunchConfiguration [Text]
lcSecurityGroups = lens _lcSecurityGroups (\ s a -> s{_lcSecurityGroups = a}) . _Default . _Coerce;
lcSpotPrice :: Lens' LaunchConfiguration (Maybe Text)
lcSpotPrice = lens _lcSpotPrice (\ s a -> s{_lcSpotPrice = a});
lcInstanceMonitoring :: Lens' LaunchConfiguration (Maybe InstanceMonitoring)
lcInstanceMonitoring = lens _lcInstanceMonitoring (\ s a -> s{_lcInstanceMonitoring = a});
lcKeyName :: Lens' LaunchConfiguration (Maybe Text)
lcKeyName = lens _lcKeyName (\ s a -> s{_lcKeyName = a});
lcClassicLinkVPCSecurityGroups :: Lens' LaunchConfiguration [Text]
lcClassicLinkVPCSecurityGroups = lens _lcClassicLinkVPCSecurityGroups (\ s a -> s{_lcClassicLinkVPCSecurityGroups = a}) . _Default . _Coerce;
lcRAMDiskId :: Lens' LaunchConfiguration (Maybe Text)
lcRAMDiskId = lens _lcRAMDiskId (\ s a -> s{_lcRAMDiskId = a});
lcKernelId :: Lens' LaunchConfiguration (Maybe Text)
lcKernelId = lens _lcKernelId (\ s a -> s{_lcKernelId = a});
lcEBSOptimized :: Lens' LaunchConfiguration (Maybe Bool)
lcEBSOptimized = lens _lcEBSOptimized (\ s a -> s{_lcEBSOptimized = a});
lcUserData :: Lens' LaunchConfiguration (Maybe Text)
lcUserData = lens _lcUserData (\ s a -> s{_lcUserData = a});
lcClassicLinkVPCId :: Lens' LaunchConfiguration (Maybe Text)
lcClassicLinkVPCId = lens _lcClassicLinkVPCId (\ s a -> s{_lcClassicLinkVPCId = a});
lcIAMInstanceProfile :: Lens' LaunchConfiguration (Maybe Text)
lcIAMInstanceProfile = lens _lcIAMInstanceProfile (\ s a -> s{_lcIAMInstanceProfile = a});
lcLaunchConfigurationARN :: Lens' LaunchConfiguration (Maybe Text)
lcLaunchConfigurationARN = lens _lcLaunchConfigurationARN (\ s a -> s{_lcLaunchConfigurationARN = a});
lcPlacementTenancy :: Lens' LaunchConfiguration (Maybe Text)
lcPlacementTenancy = lens _lcPlacementTenancy (\ s a -> s{_lcPlacementTenancy = a});
lcBlockDeviceMappings :: Lens' LaunchConfiguration [BlockDeviceMapping]
lcBlockDeviceMappings = lens _lcBlockDeviceMappings (\ s a -> s{_lcBlockDeviceMappings = a}) . _Default . _Coerce;
lcLaunchConfigurationName :: Lens' LaunchConfiguration Text
lcLaunchConfigurationName = lens _lcLaunchConfigurationName (\ s a -> s{_lcLaunchConfigurationName = a});
lcImageId :: Lens' LaunchConfiguration Text
lcImageId = lens _lcImageId (\ s a -> s{_lcImageId = a});
lcInstanceType :: Lens' LaunchConfiguration Text
lcInstanceType = lens _lcInstanceType (\ s a -> s{_lcInstanceType = a});
lcCreatedTime :: Lens' LaunchConfiguration UTCTime
lcCreatedTime = lens _lcCreatedTime (\ s a -> s{_lcCreatedTime = a}) . _Time;
instance FromXML LaunchConfiguration where
parseXML x
= LaunchConfiguration' <$>
(x .@? "AssociatePublicIpAddress") <*>
(x .@? "SecurityGroups" .!@ mempty >>=
may (parseXMLList "member"))
<*> (x .@? "SpotPrice")
<*> (x .@? "InstanceMonitoring")
<*> (x .@? "KeyName")
<*>
(x .@? "ClassicLinkVPCSecurityGroups" .!@ mempty >>=
may (parseXMLList "member"))
<*> (x .@? "RamdiskId")
<*> (x .@? "KernelId")
<*> (x .@? "EbsOptimized")
<*> (x .@? "UserData")
<*> (x .@? "ClassicLinkVPCId")
<*> (x .@? "IamInstanceProfile")
<*> (x .@? "LaunchConfigurationARN")
<*> (x .@? "PlacementTenancy")
<*>
(x .@? "BlockDeviceMappings" .!@ mempty >>=
may (parseXMLList "member"))
<*> (x .@ "LaunchConfigurationName")
<*> (x .@ "ImageId")
<*> (x .@ "InstanceType")
<*> (x .@ "CreatedTime")
instance Hashable LaunchConfiguration
instance NFData LaunchConfiguration
data LifecycleHook = LifecycleHook'
{ _lhDefaultResult :: !(Maybe Text)
, _lhLifecycleHookName :: !(Maybe Text)
, _lhHeartbeatTimeout :: !(Maybe Int)
, _lhAutoScalingGroupName :: !(Maybe Text)
, _lhNotificationMetadata :: !(Maybe Text)
, _lhGlobalTimeout :: !(Maybe Int)
, _lhNotificationTargetARN :: !(Maybe Text)
, _lhLifecycleTransition :: !(Maybe Text)
, _lhRoleARN :: !(Maybe Text)
} deriving (Eq,Read,Show,Data,Typeable,Generic)
lifecycleHook
:: LifecycleHook
lifecycleHook =
LifecycleHook'
{ _lhDefaultResult = Nothing
, _lhLifecycleHookName = Nothing
, _lhHeartbeatTimeout = Nothing
, _lhAutoScalingGroupName = Nothing
, _lhNotificationMetadata = Nothing
, _lhGlobalTimeout = Nothing
, _lhNotificationTargetARN = Nothing
, _lhLifecycleTransition = Nothing
, _lhRoleARN = Nothing
}
lhDefaultResult :: Lens' LifecycleHook (Maybe Text)
lhDefaultResult = lens _lhDefaultResult (\ s a -> s{_lhDefaultResult = a});
lhLifecycleHookName :: Lens' LifecycleHook (Maybe Text)
lhLifecycleHookName = lens _lhLifecycleHookName (\ s a -> s{_lhLifecycleHookName = a});
lhHeartbeatTimeout :: Lens' LifecycleHook (Maybe Int)
lhHeartbeatTimeout = lens _lhHeartbeatTimeout (\ s a -> s{_lhHeartbeatTimeout = a});
lhAutoScalingGroupName :: Lens' LifecycleHook (Maybe Text)
lhAutoScalingGroupName = lens _lhAutoScalingGroupName (\ s a -> s{_lhAutoScalingGroupName = a});
lhNotificationMetadata :: Lens' LifecycleHook (Maybe Text)
lhNotificationMetadata = lens _lhNotificationMetadata (\ s a -> s{_lhNotificationMetadata = a});
lhGlobalTimeout :: Lens' LifecycleHook (Maybe Int)
lhGlobalTimeout = lens _lhGlobalTimeout (\ s a -> s{_lhGlobalTimeout = a});
lhNotificationTargetARN :: Lens' LifecycleHook (Maybe Text)
lhNotificationTargetARN = lens _lhNotificationTargetARN (\ s a -> s{_lhNotificationTargetARN = a});
lhLifecycleTransition :: Lens' LifecycleHook (Maybe Text)
lhLifecycleTransition = lens _lhLifecycleTransition (\ s a -> s{_lhLifecycleTransition = a});
lhRoleARN :: Lens' LifecycleHook (Maybe Text)
lhRoleARN = lens _lhRoleARN (\ s a -> s{_lhRoleARN = a});
instance FromXML LifecycleHook where
parseXML x
= LifecycleHook' <$>
(x .@? "DefaultResult") <*>
(x .@? "LifecycleHookName")
<*> (x .@? "HeartbeatTimeout")
<*> (x .@? "AutoScalingGroupName")
<*> (x .@? "NotificationMetadata")
<*> (x .@? "GlobalTimeout")
<*> (x .@? "NotificationTargetARN")
<*> (x .@? "LifecycleTransition")
<*> (x .@? "RoleARN")
instance Hashable LifecycleHook
instance NFData LifecycleHook
data LoadBalancerState = LoadBalancerState'
{ _lbsState :: !(Maybe Text)
, _lbsLoadBalancerName :: !(Maybe Text)
} deriving (Eq,Read,Show,Data,Typeable,Generic)
loadBalancerState
:: LoadBalancerState
loadBalancerState =
LoadBalancerState'
{ _lbsState = Nothing
, _lbsLoadBalancerName = Nothing
}
lbsState :: Lens' LoadBalancerState (Maybe Text)
lbsState = lens _lbsState (\ s a -> s{_lbsState = a});
lbsLoadBalancerName :: Lens' LoadBalancerState (Maybe Text)
lbsLoadBalancerName = lens _lbsLoadBalancerName (\ s a -> s{_lbsLoadBalancerName = a});
instance FromXML LoadBalancerState where
parseXML x
= LoadBalancerState' <$>
(x .@? "State") <*> (x .@? "LoadBalancerName")
instance Hashable LoadBalancerState
instance NFData LoadBalancerState
data LoadBalancerTargetGroupState = LoadBalancerTargetGroupState'
{ _lbtgsState :: !(Maybe Text)
, _lbtgsLoadBalancerTargetGroupARN :: !(Maybe Text)
} deriving (Eq,Read,Show,Data,Typeable,Generic)
loadBalancerTargetGroupState
:: LoadBalancerTargetGroupState
loadBalancerTargetGroupState =
LoadBalancerTargetGroupState'
{ _lbtgsState = Nothing
, _lbtgsLoadBalancerTargetGroupARN = Nothing
}
lbtgsState :: Lens' LoadBalancerTargetGroupState (Maybe Text)
lbtgsState = lens _lbtgsState (\ s a -> s{_lbtgsState = a});
lbtgsLoadBalancerTargetGroupARN :: Lens' LoadBalancerTargetGroupState (Maybe Text)
lbtgsLoadBalancerTargetGroupARN = lens _lbtgsLoadBalancerTargetGroupARN (\ s a -> s{_lbtgsLoadBalancerTargetGroupARN = a});
instance FromXML LoadBalancerTargetGroupState where
parseXML x
= LoadBalancerTargetGroupState' <$>
(x .@? "State") <*>
(x .@? "LoadBalancerTargetGroupARN")
instance Hashable LoadBalancerTargetGroupState
instance NFData LoadBalancerTargetGroupState
newtype MetricCollectionType = MetricCollectionType'
{ _mctMetric :: Maybe Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
metricCollectionType
:: MetricCollectionType
metricCollectionType =
MetricCollectionType'
{ _mctMetric = Nothing
}
mctMetric :: Lens' MetricCollectionType (Maybe Text)
mctMetric = lens _mctMetric (\ s a -> s{_mctMetric = a});
instance FromXML MetricCollectionType where
parseXML x
= MetricCollectionType' <$> (x .@? "Metric")
instance Hashable MetricCollectionType
instance NFData MetricCollectionType
newtype MetricGranularityType = MetricGranularityType'
{ _mgtGranularity :: Maybe Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
metricGranularityType
:: MetricGranularityType
metricGranularityType =
MetricGranularityType'
{ _mgtGranularity = Nothing
}
mgtGranularity :: Lens' MetricGranularityType (Maybe Text)
mgtGranularity = lens _mgtGranularity (\ s a -> s{_mgtGranularity = a});
instance FromXML MetricGranularityType where
parseXML x
= MetricGranularityType' <$> (x .@? "Granularity")
instance Hashable MetricGranularityType
instance NFData MetricGranularityType
data NotificationConfiguration = NotificationConfiguration'
{ _ncTopicARN :: !(Maybe Text)
, _ncAutoScalingGroupName :: !(Maybe Text)
, _ncNotificationType :: !(Maybe Text)
} deriving (Eq,Read,Show,Data,Typeable,Generic)
notificationConfiguration
:: NotificationConfiguration
notificationConfiguration =
NotificationConfiguration'
{ _ncTopicARN = Nothing
, _ncAutoScalingGroupName = Nothing
, _ncNotificationType = Nothing
}
ncTopicARN :: Lens' NotificationConfiguration (Maybe Text)
ncTopicARN = lens _ncTopicARN (\ s a -> s{_ncTopicARN = a});
ncAutoScalingGroupName :: Lens' NotificationConfiguration (Maybe Text)
ncAutoScalingGroupName = lens _ncAutoScalingGroupName (\ s a -> s{_ncAutoScalingGroupName = a});
ncNotificationType :: Lens' NotificationConfiguration (Maybe Text)
ncNotificationType = lens _ncNotificationType (\ s a -> s{_ncNotificationType = a});
instance FromXML NotificationConfiguration where
parseXML x
= NotificationConfiguration' <$>
(x .@? "TopicARN") <*> (x .@? "AutoScalingGroupName")
<*> (x .@? "NotificationType")
instance Hashable NotificationConfiguration
instance NFData NotificationConfiguration
newtype ProcessType = ProcessType'
{ _ptProcessName :: Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
processType
:: Text
-> ProcessType
processType pProcessName_ =
ProcessType'
{ _ptProcessName = pProcessName_
}
ptProcessName :: Lens' ProcessType Text
ptProcessName = lens _ptProcessName (\ s a -> s{_ptProcessName = a});
instance FromXML ProcessType where
parseXML x = ProcessType' <$> (x .@ "ProcessName")
instance Hashable ProcessType
instance NFData ProcessType
data ScalingPolicy = ScalingPolicy'
{ _sMinAdjustmentStep :: !(Maybe Int)
, _sEstimatedInstanceWarmup :: !(Maybe Int)
, _sPolicyName :: !(Maybe Text)
, _sPolicyType :: !(Maybe Text)
, _sStepAdjustments :: !(Maybe [StepAdjustment])
, _sAdjustmentType :: !(Maybe Text)
, _sAutoScalingGroupName :: !(Maybe Text)
, _sScalingAdjustment :: !(Maybe Int)
, _sCooldown :: !(Maybe Int)
, _sPolicyARN :: !(Maybe Text)
, _sAlarms :: !(Maybe [Alarm])
, _sMetricAggregationType :: !(Maybe Text)
, _sMinAdjustmentMagnitude :: !(Maybe Int)
} deriving (Eq,Read,Show,Data,Typeable,Generic)
scalingPolicy
:: ScalingPolicy
scalingPolicy =
ScalingPolicy'
{ _sMinAdjustmentStep = Nothing
, _sEstimatedInstanceWarmup = Nothing
, _sPolicyName = Nothing
, _sPolicyType = Nothing
, _sStepAdjustments = Nothing
, _sAdjustmentType = Nothing
, _sAutoScalingGroupName = Nothing
, _sScalingAdjustment = Nothing
, _sCooldown = Nothing
, _sPolicyARN = Nothing
, _sAlarms = Nothing
, _sMetricAggregationType = Nothing
, _sMinAdjustmentMagnitude = Nothing
}
sMinAdjustmentStep :: Lens' ScalingPolicy (Maybe Int)
sMinAdjustmentStep = lens _sMinAdjustmentStep (\ s a -> s{_sMinAdjustmentStep = a});
sEstimatedInstanceWarmup :: Lens' ScalingPolicy (Maybe Int)
sEstimatedInstanceWarmup = lens _sEstimatedInstanceWarmup (\ s a -> s{_sEstimatedInstanceWarmup = a});
sPolicyName :: Lens' ScalingPolicy (Maybe Text)
sPolicyName = lens _sPolicyName (\ s a -> s{_sPolicyName = a});
sPolicyType :: Lens' ScalingPolicy (Maybe Text)
sPolicyType = lens _sPolicyType (\ s a -> s{_sPolicyType = a});
sStepAdjustments :: Lens' ScalingPolicy [StepAdjustment]
sStepAdjustments = lens _sStepAdjustments (\ s a -> s{_sStepAdjustments = a}) . _Default . _Coerce;
sAdjustmentType :: Lens' ScalingPolicy (Maybe Text)
sAdjustmentType = lens _sAdjustmentType (\ s a -> s{_sAdjustmentType = a});
sAutoScalingGroupName :: Lens' ScalingPolicy (Maybe Text)
sAutoScalingGroupName = lens _sAutoScalingGroupName (\ s a -> s{_sAutoScalingGroupName = a});
sScalingAdjustment :: Lens' ScalingPolicy (Maybe Int)
sScalingAdjustment = lens _sScalingAdjustment (\ s a -> s{_sScalingAdjustment = a});
sCooldown :: Lens' ScalingPolicy (Maybe Int)
sCooldown = lens _sCooldown (\ s a -> s{_sCooldown = a});
sPolicyARN :: Lens' ScalingPolicy (Maybe Text)
sPolicyARN = lens _sPolicyARN (\ s a -> s{_sPolicyARN = a});
sAlarms :: Lens' ScalingPolicy [Alarm]
sAlarms = lens _sAlarms (\ s a -> s{_sAlarms = a}) . _Default . _Coerce;
sMetricAggregationType :: Lens' ScalingPolicy (Maybe Text)
sMetricAggregationType = lens _sMetricAggregationType (\ s a -> s{_sMetricAggregationType = a});
sMinAdjustmentMagnitude :: Lens' ScalingPolicy (Maybe Int)
sMinAdjustmentMagnitude = lens _sMinAdjustmentMagnitude (\ s a -> s{_sMinAdjustmentMagnitude = a});
instance FromXML ScalingPolicy where
parseXML x
= ScalingPolicy' <$>
(x .@? "MinAdjustmentStep") <*>
(x .@? "EstimatedInstanceWarmup")
<*> (x .@? "PolicyName")
<*> (x .@? "PolicyType")
<*>
(x .@? "StepAdjustments" .!@ mempty >>=
may (parseXMLList "member"))
<*> (x .@? "AdjustmentType")
<*> (x .@? "AutoScalingGroupName")
<*> (x .@? "ScalingAdjustment")
<*> (x .@? "Cooldown")
<*> (x .@? "PolicyARN")
<*>
(x .@? "Alarms" .!@ mempty >>=
may (parseXMLList "member"))
<*> (x .@? "MetricAggregationType")
<*> (x .@? "MinAdjustmentMagnitude")
instance Hashable ScalingPolicy
instance NFData ScalingPolicy
data ScalingProcessQuery = ScalingProcessQuery'
{ _spqScalingProcesses :: !(Maybe [Text])
, _spqAutoScalingGroupName :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
scalingProcessQuery
:: Text
-> ScalingProcessQuery
scalingProcessQuery pAutoScalingGroupName_ =
ScalingProcessQuery'
{ _spqScalingProcesses = Nothing
, _spqAutoScalingGroupName = pAutoScalingGroupName_
}
spqScalingProcesses :: Lens' ScalingProcessQuery [Text]
spqScalingProcesses = lens _spqScalingProcesses (\ s a -> s{_spqScalingProcesses = a}) . _Default . _Coerce;
spqAutoScalingGroupName :: Lens' ScalingProcessQuery Text
spqAutoScalingGroupName = lens _spqAutoScalingGroupName (\ s a -> s{_spqAutoScalingGroupName = a});
instance Hashable ScalingProcessQuery
instance NFData ScalingProcessQuery
instance ToQuery ScalingProcessQuery where
toQuery ScalingProcessQuery'{..}
= mconcat
["ScalingProcesses" =:
toQuery
(toQueryList "member" <$> _spqScalingProcesses),
"AutoScalingGroupName" =: _spqAutoScalingGroupName]
data ScheduledUpdateGroupAction = ScheduledUpdateGroupAction'
{ _sugaScheduledActionARN :: !(Maybe Text)
, _sugaStartTime :: !(Maybe ISO8601)
, _sugaTime :: !(Maybe ISO8601)
, _sugaScheduledActionName :: !(Maybe Text)
, _sugaMaxSize :: !(Maybe Int)
, _sugaRecurrence :: !(Maybe Text)
, _sugaDesiredCapacity :: !(Maybe Int)
, _sugaMinSize :: !(Maybe Int)
, _sugaAutoScalingGroupName :: !(Maybe Text)
, _sugaEndTime :: !(Maybe ISO8601)
} deriving (Eq,Read,Show,Data,Typeable,Generic)
scheduledUpdateGroupAction
:: ScheduledUpdateGroupAction
scheduledUpdateGroupAction =
ScheduledUpdateGroupAction'
{ _sugaScheduledActionARN = Nothing
, _sugaStartTime = Nothing
, _sugaTime = Nothing
, _sugaScheduledActionName = Nothing
, _sugaMaxSize = Nothing
, _sugaRecurrence = Nothing
, _sugaDesiredCapacity = Nothing
, _sugaMinSize = Nothing
, _sugaAutoScalingGroupName = Nothing
, _sugaEndTime = Nothing
}
sugaScheduledActionARN :: Lens' ScheduledUpdateGroupAction (Maybe Text)
sugaScheduledActionARN = lens _sugaScheduledActionARN (\ s a -> s{_sugaScheduledActionARN = a});
sugaStartTime :: Lens' ScheduledUpdateGroupAction (Maybe UTCTime)
sugaStartTime = lens _sugaStartTime (\ s a -> s{_sugaStartTime = a}) . mapping _Time;
sugaTime :: Lens' ScheduledUpdateGroupAction (Maybe UTCTime)
sugaTime = lens _sugaTime (\ s a -> s{_sugaTime = a}) . mapping _Time;
sugaScheduledActionName :: Lens' ScheduledUpdateGroupAction (Maybe Text)
sugaScheduledActionName = lens _sugaScheduledActionName (\ s a -> s{_sugaScheduledActionName = a});
sugaMaxSize :: Lens' ScheduledUpdateGroupAction (Maybe Int)
sugaMaxSize = lens _sugaMaxSize (\ s a -> s{_sugaMaxSize = a});
sugaRecurrence :: Lens' ScheduledUpdateGroupAction (Maybe Text)
sugaRecurrence = lens _sugaRecurrence (\ s a -> s{_sugaRecurrence = a});
sugaDesiredCapacity :: Lens' ScheduledUpdateGroupAction (Maybe Int)
sugaDesiredCapacity = lens _sugaDesiredCapacity (\ s a -> s{_sugaDesiredCapacity = a});
sugaMinSize :: Lens' ScheduledUpdateGroupAction (Maybe Int)
sugaMinSize = lens _sugaMinSize (\ s a -> s{_sugaMinSize = a});
sugaAutoScalingGroupName :: Lens' ScheduledUpdateGroupAction (Maybe Text)
sugaAutoScalingGroupName = lens _sugaAutoScalingGroupName (\ s a -> s{_sugaAutoScalingGroupName = a});
sugaEndTime :: Lens' ScheduledUpdateGroupAction (Maybe UTCTime)
sugaEndTime = lens _sugaEndTime (\ s a -> s{_sugaEndTime = a}) . mapping _Time;
instance FromXML ScheduledUpdateGroupAction where
parseXML x
= ScheduledUpdateGroupAction' <$>
(x .@? "ScheduledActionARN") <*> (x .@? "StartTime")
<*> (x .@? "Time")
<*> (x .@? "ScheduledActionName")
<*> (x .@? "MaxSize")
<*> (x .@? "Recurrence")
<*> (x .@? "DesiredCapacity")
<*> (x .@? "MinSize")
<*> (x .@? "AutoScalingGroupName")
<*> (x .@? "EndTime")
instance Hashable ScheduledUpdateGroupAction
instance NFData ScheduledUpdateGroupAction
data StepAdjustment = StepAdjustment'
{ _saMetricIntervalLowerBound :: !(Maybe Double)
, _saMetricIntervalUpperBound :: !(Maybe Double)
, _saScalingAdjustment :: !Int
} deriving (Eq,Read,Show,Data,Typeable,Generic)
stepAdjustment
:: Int
-> StepAdjustment
stepAdjustment pScalingAdjustment_ =
StepAdjustment'
{ _saMetricIntervalLowerBound = Nothing
, _saMetricIntervalUpperBound = Nothing
, _saScalingAdjustment = pScalingAdjustment_
}
saMetricIntervalLowerBound :: Lens' StepAdjustment (Maybe Double)
saMetricIntervalLowerBound = lens _saMetricIntervalLowerBound (\ s a -> s{_saMetricIntervalLowerBound = a});
saMetricIntervalUpperBound :: Lens' StepAdjustment (Maybe Double)
saMetricIntervalUpperBound = lens _saMetricIntervalUpperBound (\ s a -> s{_saMetricIntervalUpperBound = a});
saScalingAdjustment :: Lens' StepAdjustment Int
saScalingAdjustment = lens _saScalingAdjustment (\ s a -> s{_saScalingAdjustment = a});
instance FromXML StepAdjustment where
parseXML x
= StepAdjustment' <$>
(x .@? "MetricIntervalLowerBound") <*>
(x .@? "MetricIntervalUpperBound")
<*> (x .@ "ScalingAdjustment")
instance Hashable StepAdjustment
instance NFData StepAdjustment
instance ToQuery StepAdjustment where
toQuery StepAdjustment'{..}
= mconcat
["MetricIntervalLowerBound" =:
_saMetricIntervalLowerBound,
"MetricIntervalUpperBound" =:
_saMetricIntervalUpperBound,
"ScalingAdjustment" =: _saScalingAdjustment]
data SuspendedProcess = SuspendedProcess'
{ _spProcessName :: !(Maybe Text)
, _spSuspensionReason :: !(Maybe Text)
} deriving (Eq,Read,Show,Data,Typeable,Generic)
suspendedProcess
:: SuspendedProcess
suspendedProcess =
SuspendedProcess'
{ _spProcessName = Nothing
, _spSuspensionReason = Nothing
}
spProcessName :: Lens' SuspendedProcess (Maybe Text)
spProcessName = lens _spProcessName (\ s a -> s{_spProcessName = a});
spSuspensionReason :: Lens' SuspendedProcess (Maybe Text)
spSuspensionReason = lens _spSuspensionReason (\ s a -> s{_spSuspensionReason = a});
instance FromXML SuspendedProcess where
parseXML x
= SuspendedProcess' <$>
(x .@? "ProcessName") <*> (x .@? "SuspensionReason")
instance Hashable SuspendedProcess
instance NFData SuspendedProcess
data Tag = Tag'
{ _tagKey :: !Text
, _tagResourceId :: !Text
, _tagResourceType :: !Text
, _tagPropagateAtLaunch :: !Bool
, _tagValue :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
tag
:: Text
-> Text
-> Text
-> Bool
-> Text
-> Tag
tag pKey_ pResourceId_ pResourceType_ pPropagateAtLaunch_ pValue_ =
Tag'
{ _tagKey = pKey_
, _tagResourceId = pResourceId_
, _tagResourceType = pResourceType_
, _tagPropagateAtLaunch = pPropagateAtLaunch_
, _tagValue = pValue_
}
tagKey :: Lens' Tag Text
tagKey = lens _tagKey (\ s a -> s{_tagKey = a});
tagResourceId :: Lens' Tag Text
tagResourceId = lens _tagResourceId (\ s a -> s{_tagResourceId = a});
tagResourceType :: Lens' Tag Text
tagResourceType = lens _tagResourceType (\ s a -> s{_tagResourceType = a});
tagPropagateAtLaunch :: Lens' Tag Bool
tagPropagateAtLaunch = lens _tagPropagateAtLaunch (\ s a -> s{_tagPropagateAtLaunch = a});
tagValue :: Lens' Tag Text
tagValue = lens _tagValue (\ s a -> s{_tagValue = a});
instance Hashable Tag
instance NFData Tag
instance ToQuery Tag where
toQuery Tag'{..}
= mconcat
["Key" =: _tagKey, "ResourceId" =: _tagResourceId,
"ResourceType" =: _tagResourceType,
"PropagateAtLaunch" =: _tagPropagateAtLaunch,
"Value" =: _tagValue]
data TagDescription = TagDescription'
{ _tdResourceId :: !Text
, _tdResourceType :: !Text
, _tdKey :: !Text
, _tdPropagateAtLaunch :: !Bool
, _tdValue :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
tagDescription
:: Text
-> Text
-> Text
-> Bool
-> Text
-> TagDescription
tagDescription pResourceId_ pResourceType_ pKey_ pPropagateAtLaunch_ pValue_ =
TagDescription'
{ _tdResourceId = pResourceId_
, _tdResourceType = pResourceType_
, _tdKey = pKey_
, _tdPropagateAtLaunch = pPropagateAtLaunch_
, _tdValue = pValue_
}
tdResourceId :: Lens' TagDescription Text
tdResourceId = lens _tdResourceId (\ s a -> s{_tdResourceId = a});
tdResourceType :: Lens' TagDescription Text
tdResourceType = lens _tdResourceType (\ s a -> s{_tdResourceType = a});
tdKey :: Lens' TagDescription Text
tdKey = lens _tdKey (\ s a -> s{_tdKey = a});
tdPropagateAtLaunch :: Lens' TagDescription Bool
tdPropagateAtLaunch = lens _tdPropagateAtLaunch (\ s a -> s{_tdPropagateAtLaunch = a});
tdValue :: Lens' TagDescription Text
tdValue = lens _tdValue (\ s a -> s{_tdValue = a});
instance FromXML TagDescription where
parseXML x
= TagDescription' <$>
(x .@ "ResourceId") <*> (x .@ "ResourceType") <*>
(x .@ "Key")
<*> (x .@ "PropagateAtLaunch")
<*> (x .@ "Value")
instance Hashable TagDescription
instance NFData TagDescription