{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}

-- Derived from AWS service descriptions, licensed under Apache 2.0.

-- |
-- Module      : Amazonka.AutoScaling.Types.AutoScalingGroup
-- Copyright   : (c) 2013-2021 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
module Amazonka.AutoScaling.Types.AutoScalingGroup where

import Amazonka.AutoScaling.Types.EnabledMetric
import Amazonka.AutoScaling.Types.Instance
import Amazonka.AutoScaling.Types.LaunchTemplateSpecification
import Amazonka.AutoScaling.Types.MixedInstancesPolicy
import Amazonka.AutoScaling.Types.SuspendedProcess
import Amazonka.AutoScaling.Types.TagDescription
import Amazonka.AutoScaling.Types.WarmPoolConfiguration
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude

-- | Describes an Auto Scaling group.
--
-- /See:/ 'newAutoScalingGroup' smart constructor.
data AutoScalingGroup = AutoScalingGroup'
  { -- | The current state of the group when the DeleteAutoScalingGroup operation
    -- is in progress.
    AutoScalingGroup -> Maybe Text
status :: Prelude.Maybe Prelude.Text,
    -- | Reserved.
    AutoScalingGroup -> Maybe Text
context :: Prelude.Maybe Prelude.Text,
    -- | The termination policies for the group.
    AutoScalingGroup -> Maybe [Text]
terminationPolicies :: Prelude.Maybe [Prelude.Text],
    -- | The amount of time, in seconds, that Amazon EC2 Auto Scaling waits
    -- before checking the health status of an EC2 instance that has come into
    -- service.
    AutoScalingGroup -> Maybe Int
healthCheckGracePeriod :: Prelude.Maybe Prelude.Int,
    -- | The Amazon Resource Name (ARN) of the service-linked role that the Auto
    -- Scaling group uses to call other Amazon Web Services on your behalf.
    AutoScalingGroup -> Maybe Text
serviceLinkedRoleARN :: Prelude.Maybe Prelude.Text,
    -- | Indicates whether newly launched instances are protected from
    -- termination by Amazon EC2 Auto Scaling when scaling in.
    AutoScalingGroup -> Maybe Bool
newInstancesProtectedFromScaleIn' :: Prelude.Maybe Prelude.Bool,
    -- | One or more subnet IDs, if applicable, separated by commas.
    AutoScalingGroup -> Maybe Text
vPCZoneIdentifier :: Prelude.Maybe Prelude.Text,
    -- | The Amazon Resource Names (ARN) of the target groups for your load
    -- balancer.
    AutoScalingGroup -> Maybe [Text]
targetGroupARNs :: Prelude.Maybe [Prelude.Text],
    -- | The maximum amount of time, in seconds, that an instance can be in
    -- service.
    --
    -- Valid Range: Minimum value of 0.
    AutoScalingGroup -> Maybe Int
maxInstanceLifetime :: Prelude.Maybe Prelude.Int,
    -- | The mixed instances policy for the group.
    AutoScalingGroup -> Maybe MixedInstancesPolicy
mixedInstancesPolicy :: Prelude.Maybe MixedInstancesPolicy,
    -- | The metrics enabled for the group.
    AutoScalingGroup -> Maybe [EnabledMetric]
enabledMetrics :: Prelude.Maybe [EnabledMetric],
    -- | The name of the associated launch configuration.
    AutoScalingGroup -> Maybe Text
launchConfigurationName :: Prelude.Maybe Prelude.Text,
    -- | The EC2 instances associated with the group.
    AutoScalingGroup -> Maybe [Instance]
instances :: Prelude.Maybe [Instance],
    -- | The launch template for the group.
    AutoScalingGroup -> Maybe LaunchTemplateSpecification
launchTemplate :: Prelude.Maybe LaunchTemplateSpecification,
    -- | The warm pool for the group.
    AutoScalingGroup -> Maybe WarmPoolConfiguration
warmPoolConfiguration :: Prelude.Maybe WarmPoolConfiguration,
    -- | Indicates whether Capacity Rebalancing is enabled.
    AutoScalingGroup -> Maybe Bool
capacityRebalance :: Prelude.Maybe Prelude.Bool,
    -- | The Amazon Resource Name (ARN) of the Auto Scaling group.
    AutoScalingGroup -> Maybe Text
autoScalingGroupARN :: Prelude.Maybe Prelude.Text,
    -- | The predicted capacity of the group when it has a predictive scaling
    -- policy.
    AutoScalingGroup -> Maybe Int
predictedCapacity :: Prelude.Maybe Prelude.Int,
    -- | The current size of the warm pool.
    AutoScalingGroup -> Maybe Int
warmPoolSize :: Prelude.Maybe Prelude.Int,
    -- | The name of the placement group into which to launch your instances, if
    -- any.
    AutoScalingGroup -> Maybe Text
placementGroup :: Prelude.Maybe Prelude.Text,
    -- | The suspended processes associated with the group.
    AutoScalingGroup -> Maybe [SuspendedProcess]
suspendedProcesses :: Prelude.Maybe [SuspendedProcess],
    -- | One or more load balancers associated with the group.
    AutoScalingGroup -> Maybe [Text]
loadBalancerNames :: Prelude.Maybe [Prelude.Text],
    -- | The tags for the group.
    AutoScalingGroup -> Maybe [TagDescription]
tags :: Prelude.Maybe [TagDescription],
    -- | The name of the Auto Scaling group.
    AutoScalingGroup -> Text
autoScalingGroupName :: Prelude.Text,
    -- | The minimum size of the group.
    AutoScalingGroup -> Int
minSize :: Prelude.Int,
    -- | The maximum size of the group.
    AutoScalingGroup -> Int
maxSize :: Prelude.Int,
    -- | The desired size of the group.
    AutoScalingGroup -> Int
desiredCapacity :: Prelude.Int,
    -- | The duration of the default cooldown period, in seconds.
    AutoScalingGroup -> Int
defaultCooldown :: Prelude.Int,
    -- | One or more Availability Zones for the group.
    AutoScalingGroup -> [Text]
availabilityZones :: [Prelude.Text],
    -- | The service to use for the health checks. The valid values are @EC2@ and
    -- @ELB@. If you configure an Auto Scaling group to use @ELB@ health
    -- checks, it considers the instance unhealthy if it fails either the EC2
    -- status checks or the load balancer health checks.
    AutoScalingGroup -> Text
healthCheckType :: Prelude.Text,
    -- | The date and time the group was created.
    AutoScalingGroup -> ISO8601
createdTime :: Core.ISO8601
  }
  deriving (AutoScalingGroup -> AutoScalingGroup -> Bool
(AutoScalingGroup -> AutoScalingGroup -> Bool)
-> (AutoScalingGroup -> AutoScalingGroup -> Bool)
-> Eq AutoScalingGroup
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: AutoScalingGroup -> AutoScalingGroup -> Bool
$c/= :: AutoScalingGroup -> AutoScalingGroup -> Bool
== :: AutoScalingGroup -> AutoScalingGroup -> Bool
$c== :: AutoScalingGroup -> AutoScalingGroup -> Bool
Prelude.Eq, ReadPrec [AutoScalingGroup]
ReadPrec AutoScalingGroup
Int -> ReadS AutoScalingGroup
ReadS [AutoScalingGroup]
(Int -> ReadS AutoScalingGroup)
-> ReadS [AutoScalingGroup]
-> ReadPrec AutoScalingGroup
-> ReadPrec [AutoScalingGroup]
-> Read AutoScalingGroup
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [AutoScalingGroup]
$creadListPrec :: ReadPrec [AutoScalingGroup]
readPrec :: ReadPrec AutoScalingGroup
$creadPrec :: ReadPrec AutoScalingGroup
readList :: ReadS [AutoScalingGroup]
$creadList :: ReadS [AutoScalingGroup]
readsPrec :: Int -> ReadS AutoScalingGroup
$creadsPrec :: Int -> ReadS AutoScalingGroup
Prelude.Read, Int -> AutoScalingGroup -> ShowS
[AutoScalingGroup] -> ShowS
AutoScalingGroup -> String
(Int -> AutoScalingGroup -> ShowS)
-> (AutoScalingGroup -> String)
-> ([AutoScalingGroup] -> ShowS)
-> Show AutoScalingGroup
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [AutoScalingGroup] -> ShowS
$cshowList :: [AutoScalingGroup] -> ShowS
show :: AutoScalingGroup -> String
$cshow :: AutoScalingGroup -> String
showsPrec :: Int -> AutoScalingGroup -> ShowS
$cshowsPrec :: Int -> AutoScalingGroup -> ShowS
Prelude.Show, (forall x. AutoScalingGroup -> Rep AutoScalingGroup x)
-> (forall x. Rep AutoScalingGroup x -> AutoScalingGroup)
-> Generic AutoScalingGroup
forall x. Rep AutoScalingGroup x -> AutoScalingGroup
forall x. AutoScalingGroup -> Rep AutoScalingGroup x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep AutoScalingGroup x -> AutoScalingGroup
$cfrom :: forall x. AutoScalingGroup -> Rep AutoScalingGroup x
Prelude.Generic)

-- |
-- Create a value of 'AutoScalingGroup' with all optional fields omitted.
--
-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.
--
-- The following record fields are available, with the corresponding lenses provided
-- for backwards compatibility:
--
-- 'status', 'autoScalingGroup_status' - The current state of the group when the DeleteAutoScalingGroup operation
-- is in progress.
--
-- 'context', 'autoScalingGroup_context' - Reserved.
--
-- 'terminationPolicies', 'autoScalingGroup_terminationPolicies' - The termination policies for the group.
--
-- 'healthCheckGracePeriod', 'autoScalingGroup_healthCheckGracePeriod' - The amount of time, in seconds, that Amazon EC2 Auto Scaling waits
-- before checking the health status of an EC2 instance that has come into
-- service.
--
-- 'serviceLinkedRoleARN', 'autoScalingGroup_serviceLinkedRoleARN' - The Amazon Resource Name (ARN) of the service-linked role that the Auto
-- Scaling group uses to call other Amazon Web Services on your behalf.
--
-- 'newInstancesProtectedFromScaleIn'', 'autoScalingGroup_newInstancesProtectedFromScaleIn' - Indicates whether newly launched instances are protected from
-- termination by Amazon EC2 Auto Scaling when scaling in.
--
-- 'vPCZoneIdentifier', 'autoScalingGroup_vPCZoneIdentifier' - One or more subnet IDs, if applicable, separated by commas.
--
-- 'targetGroupARNs', 'autoScalingGroup_targetGroupARNs' - The Amazon Resource Names (ARN) of the target groups for your load
-- balancer.
--
-- 'maxInstanceLifetime', 'autoScalingGroup_maxInstanceLifetime' - The maximum amount of time, in seconds, that an instance can be in
-- service.
--
-- Valid Range: Minimum value of 0.
--
-- 'mixedInstancesPolicy', 'autoScalingGroup_mixedInstancesPolicy' - The mixed instances policy for the group.
--
-- 'enabledMetrics', 'autoScalingGroup_enabledMetrics' - The metrics enabled for the group.
--
-- 'launchConfigurationName', 'autoScalingGroup_launchConfigurationName' - The name of the associated launch configuration.
--
-- 'instances', 'autoScalingGroup_instances' - The EC2 instances associated with the group.
--
-- 'launchTemplate', 'autoScalingGroup_launchTemplate' - The launch template for the group.
--
-- 'warmPoolConfiguration', 'autoScalingGroup_warmPoolConfiguration' - The warm pool for the group.
--
-- 'capacityRebalance', 'autoScalingGroup_capacityRebalance' - Indicates whether Capacity Rebalancing is enabled.
--
-- 'autoScalingGroupARN', 'autoScalingGroup_autoScalingGroupARN' - The Amazon Resource Name (ARN) of the Auto Scaling group.
--
-- 'predictedCapacity', 'autoScalingGroup_predictedCapacity' - The predicted capacity of the group when it has a predictive scaling
-- policy.
--
-- 'warmPoolSize', 'autoScalingGroup_warmPoolSize' - The current size of the warm pool.
--
-- 'placementGroup', 'autoScalingGroup_placementGroup' - The name of the placement group into which to launch your instances, if
-- any.
--
-- 'suspendedProcesses', 'autoScalingGroup_suspendedProcesses' - The suspended processes associated with the group.
--
-- 'loadBalancerNames', 'autoScalingGroup_loadBalancerNames' - One or more load balancers associated with the group.
--
-- 'tags', 'autoScalingGroup_tags' - The tags for the group.
--
-- 'autoScalingGroupName', 'autoScalingGroup_autoScalingGroupName' - The name of the Auto Scaling group.
--
-- 'minSize', 'autoScalingGroup_minSize' - The minimum size of the group.
--
-- 'maxSize', 'autoScalingGroup_maxSize' - The maximum size of the group.
--
-- 'desiredCapacity', 'autoScalingGroup_desiredCapacity' - The desired size of the group.
--
-- 'defaultCooldown', 'autoScalingGroup_defaultCooldown' - The duration of the default cooldown period, in seconds.
--
-- 'availabilityZones', 'autoScalingGroup_availabilityZones' - One or more Availability Zones for the group.
--
-- 'healthCheckType', 'autoScalingGroup_healthCheckType' - The service to use for the health checks. The valid values are @EC2@ and
-- @ELB@. If you configure an Auto Scaling group to use @ELB@ health
-- checks, it considers the instance unhealthy if it fails either the EC2
-- status checks or the load balancer health checks.
--
-- 'createdTime', 'autoScalingGroup_createdTime' - The date and time the group was created.
newAutoScalingGroup ::
  -- | 'autoScalingGroupName'
  Prelude.Text ->
  -- | 'minSize'
  Prelude.Int ->
  -- | 'maxSize'
  Prelude.Int ->
  -- | 'desiredCapacity'
  Prelude.Int ->
  -- | 'defaultCooldown'
  Prelude.Int ->
  -- | 'healthCheckType'
  Prelude.Text ->
  -- | 'createdTime'
  Prelude.UTCTime ->
  AutoScalingGroup
newAutoScalingGroup :: Text
-> Int -> Int -> Int -> Int -> Text -> UTCTime -> AutoScalingGroup
newAutoScalingGroup
  Text
pAutoScalingGroupName_
  Int
pMinSize_
  Int
pMaxSize_
  Int
pDesiredCapacity_
  Int
pDefaultCooldown_
  Text
pHealthCheckType_
  UTCTime
pCreatedTime_ =
    AutoScalingGroup' :: Maybe Text
-> Maybe Text
-> Maybe [Text]
-> Maybe Int
-> Maybe Text
-> Maybe Bool
-> Maybe Text
-> Maybe [Text]
-> Maybe Int
-> Maybe MixedInstancesPolicy
-> Maybe [EnabledMetric]
-> Maybe Text
-> Maybe [Instance]
-> Maybe LaunchTemplateSpecification
-> Maybe WarmPoolConfiguration
-> Maybe Bool
-> Maybe Text
-> Maybe Int
-> Maybe Int
-> Maybe Text
-> Maybe [SuspendedProcess]
-> Maybe [Text]
-> Maybe [TagDescription]
-> Text
-> Int
-> Int
-> Int
-> Int
-> [Text]
-> Text
-> ISO8601
-> AutoScalingGroup
AutoScalingGroup'
      { $sel:status:AutoScalingGroup' :: Maybe Text
status = Maybe Text
forall a. Maybe a
Prelude.Nothing,
        $sel:context:AutoScalingGroup' :: Maybe Text
context = Maybe Text
forall a. Maybe a
Prelude.Nothing,
        $sel:terminationPolicies:AutoScalingGroup' :: Maybe [Text]
terminationPolicies = Maybe [Text]
forall a. Maybe a
Prelude.Nothing,
        $sel:healthCheckGracePeriod:AutoScalingGroup' :: Maybe Int
healthCheckGracePeriod = Maybe Int
forall a. Maybe a
Prelude.Nothing,
        $sel:serviceLinkedRoleARN:AutoScalingGroup' :: Maybe Text
serviceLinkedRoleARN = Maybe Text
forall a. Maybe a
Prelude.Nothing,
        $sel:newInstancesProtectedFromScaleIn':AutoScalingGroup' :: Maybe Bool
newInstancesProtectedFromScaleIn' = Maybe Bool
forall a. Maybe a
Prelude.Nothing,
        $sel:vPCZoneIdentifier:AutoScalingGroup' :: Maybe Text
vPCZoneIdentifier = Maybe Text
forall a. Maybe a
Prelude.Nothing,
        $sel:targetGroupARNs:AutoScalingGroup' :: Maybe [Text]
targetGroupARNs = Maybe [Text]
forall a. Maybe a
Prelude.Nothing,
        $sel:maxInstanceLifetime:AutoScalingGroup' :: Maybe Int
maxInstanceLifetime = Maybe Int
forall a. Maybe a
Prelude.Nothing,
        $sel:mixedInstancesPolicy:AutoScalingGroup' :: Maybe MixedInstancesPolicy
mixedInstancesPolicy = Maybe MixedInstancesPolicy
forall a. Maybe a
Prelude.Nothing,
        $sel:enabledMetrics:AutoScalingGroup' :: Maybe [EnabledMetric]
enabledMetrics = Maybe [EnabledMetric]
forall a. Maybe a
Prelude.Nothing,
        $sel:launchConfigurationName:AutoScalingGroup' :: Maybe Text
launchConfigurationName = Maybe Text
forall a. Maybe a
Prelude.Nothing,
        $sel:instances:AutoScalingGroup' :: Maybe [Instance]
instances = Maybe [Instance]
forall a. Maybe a
Prelude.Nothing,
        $sel:launchTemplate:AutoScalingGroup' :: Maybe LaunchTemplateSpecification
launchTemplate = Maybe LaunchTemplateSpecification
forall a. Maybe a
Prelude.Nothing,
        $sel:warmPoolConfiguration:AutoScalingGroup' :: Maybe WarmPoolConfiguration
warmPoolConfiguration = Maybe WarmPoolConfiguration
forall a. Maybe a
Prelude.Nothing,
        $sel:capacityRebalance:AutoScalingGroup' :: Maybe Bool
capacityRebalance = Maybe Bool
forall a. Maybe a
Prelude.Nothing,
        $sel:autoScalingGroupARN:AutoScalingGroup' :: Maybe Text
autoScalingGroupARN = Maybe Text
forall a. Maybe a
Prelude.Nothing,
        $sel:predictedCapacity:AutoScalingGroup' :: Maybe Int
predictedCapacity = Maybe Int
forall a. Maybe a
Prelude.Nothing,
        $sel:warmPoolSize:AutoScalingGroup' :: Maybe Int
warmPoolSize = Maybe Int
forall a. Maybe a
Prelude.Nothing,
        $sel:placementGroup:AutoScalingGroup' :: Maybe Text
placementGroup = Maybe Text
forall a. Maybe a
Prelude.Nothing,
        $sel:suspendedProcesses:AutoScalingGroup' :: Maybe [SuspendedProcess]
suspendedProcesses = Maybe [SuspendedProcess]
forall a. Maybe a
Prelude.Nothing,
        $sel:loadBalancerNames:AutoScalingGroup' :: Maybe [Text]
loadBalancerNames = Maybe [Text]
forall a. Maybe a
Prelude.Nothing,
        $sel:tags:AutoScalingGroup' :: Maybe [TagDescription]
tags = Maybe [TagDescription]
forall a. Maybe a
Prelude.Nothing,
        $sel:autoScalingGroupName:AutoScalingGroup' :: Text
autoScalingGroupName = Text
pAutoScalingGroupName_,
        $sel:minSize:AutoScalingGroup' :: Int
minSize = Int
pMinSize_,
        $sel:maxSize:AutoScalingGroup' :: Int
maxSize = Int
pMaxSize_,
        $sel:desiredCapacity:AutoScalingGroup' :: Int
desiredCapacity = Int
pDesiredCapacity_,
        $sel:defaultCooldown:AutoScalingGroup' :: Int
defaultCooldown = Int
pDefaultCooldown_,
        $sel:availabilityZones:AutoScalingGroup' :: [Text]
availabilityZones = [Text]
forall a. Monoid a => a
Prelude.mempty,
        $sel:healthCheckType:AutoScalingGroup' :: Text
healthCheckType = Text
pHealthCheckType_,
        $sel:createdTime:AutoScalingGroup' :: ISO8601
createdTime = Tagged UTCTime (Identity UTCTime)
-> Tagged ISO8601 (Identity ISO8601)
forall (a :: Format). Iso' (Time a) UTCTime
Core._Time (Tagged UTCTime (Identity UTCTime)
 -> Tagged ISO8601 (Identity ISO8601))
-> UTCTime -> ISO8601
forall t b. AReview t b -> b -> t
Lens.# UTCTime
pCreatedTime_
      }

-- | The current state of the group when the DeleteAutoScalingGroup operation
-- is in progress.
autoScalingGroup_status :: Lens.Lens' AutoScalingGroup (Prelude.Maybe Prelude.Text)
autoScalingGroup_status :: (Maybe Text -> f (Maybe Text))
-> AutoScalingGroup -> f AutoScalingGroup
autoScalingGroup_status = (AutoScalingGroup -> Maybe Text)
-> (AutoScalingGroup -> Maybe Text -> AutoScalingGroup)
-> Lens AutoScalingGroup AutoScalingGroup (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutoScalingGroup' {Maybe Text
status :: Maybe Text
$sel:status:AutoScalingGroup' :: AutoScalingGroup -> Maybe Text
status} -> Maybe Text
status) (\s :: AutoScalingGroup
s@AutoScalingGroup' {} Maybe Text
a -> AutoScalingGroup
s {$sel:status:AutoScalingGroup' :: Maybe Text
status = Maybe Text
a} :: AutoScalingGroup)

-- | Reserved.
autoScalingGroup_context :: Lens.Lens' AutoScalingGroup (Prelude.Maybe Prelude.Text)
autoScalingGroup_context :: (Maybe Text -> f (Maybe Text))
-> AutoScalingGroup -> f AutoScalingGroup
autoScalingGroup_context = (AutoScalingGroup -> Maybe Text)
-> (AutoScalingGroup -> Maybe Text -> AutoScalingGroup)
-> Lens AutoScalingGroup AutoScalingGroup (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutoScalingGroup' {Maybe Text
context :: Maybe Text
$sel:context:AutoScalingGroup' :: AutoScalingGroup -> Maybe Text
context} -> Maybe Text
context) (\s :: AutoScalingGroup
s@AutoScalingGroup' {} Maybe Text
a -> AutoScalingGroup
s {$sel:context:AutoScalingGroup' :: Maybe Text
context = Maybe Text
a} :: AutoScalingGroup)

-- | The termination policies for the group.
autoScalingGroup_terminationPolicies :: Lens.Lens' AutoScalingGroup (Prelude.Maybe [Prelude.Text])
autoScalingGroup_terminationPolicies :: (Maybe [Text] -> f (Maybe [Text]))
-> AutoScalingGroup -> f AutoScalingGroup
autoScalingGroup_terminationPolicies = (AutoScalingGroup -> Maybe [Text])
-> (AutoScalingGroup -> Maybe [Text] -> AutoScalingGroup)
-> Lens
     AutoScalingGroup AutoScalingGroup (Maybe [Text]) (Maybe [Text])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutoScalingGroup' {Maybe [Text]
terminationPolicies :: Maybe [Text]
$sel:terminationPolicies:AutoScalingGroup' :: AutoScalingGroup -> Maybe [Text]
terminationPolicies} -> Maybe [Text]
terminationPolicies) (\s :: AutoScalingGroup
s@AutoScalingGroup' {} Maybe [Text]
a -> AutoScalingGroup
s {$sel:terminationPolicies:AutoScalingGroup' :: Maybe [Text]
terminationPolicies = Maybe [Text]
a} :: AutoScalingGroup) ((Maybe [Text] -> f (Maybe [Text]))
 -> AutoScalingGroup -> f AutoScalingGroup)
-> ((Maybe [Text] -> f (Maybe [Text]))
    -> Maybe [Text] -> f (Maybe [Text]))
-> (Maybe [Text] -> f (Maybe [Text]))
-> AutoScalingGroup
-> f AutoScalingGroup
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Text] [Text] [Text] [Text]
-> Iso (Maybe [Text]) (Maybe [Text]) (Maybe [Text]) (Maybe [Text])
forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping AnIso [Text] [Text] [Text] [Text]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The amount of time, in seconds, that Amazon EC2 Auto Scaling waits
-- before checking the health status of an EC2 instance that has come into
-- service.
autoScalingGroup_healthCheckGracePeriod :: Lens.Lens' AutoScalingGroup (Prelude.Maybe Prelude.Int)
autoScalingGroup_healthCheckGracePeriod :: (Maybe Int -> f (Maybe Int))
-> AutoScalingGroup -> f AutoScalingGroup
autoScalingGroup_healthCheckGracePeriod = (AutoScalingGroup -> Maybe Int)
-> (AutoScalingGroup -> Maybe Int -> AutoScalingGroup)
-> Lens AutoScalingGroup AutoScalingGroup (Maybe Int) (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutoScalingGroup' {Maybe Int
healthCheckGracePeriod :: Maybe Int
$sel:healthCheckGracePeriod:AutoScalingGroup' :: AutoScalingGroup -> Maybe Int
healthCheckGracePeriod} -> Maybe Int
healthCheckGracePeriod) (\s :: AutoScalingGroup
s@AutoScalingGroup' {} Maybe Int
a -> AutoScalingGroup
s {$sel:healthCheckGracePeriod:AutoScalingGroup' :: Maybe Int
healthCheckGracePeriod = Maybe Int
a} :: AutoScalingGroup)

-- | The Amazon Resource Name (ARN) of the service-linked role that the Auto
-- Scaling group uses to call other Amazon Web Services on your behalf.
autoScalingGroup_serviceLinkedRoleARN :: Lens.Lens' AutoScalingGroup (Prelude.Maybe Prelude.Text)
autoScalingGroup_serviceLinkedRoleARN :: (Maybe Text -> f (Maybe Text))
-> AutoScalingGroup -> f AutoScalingGroup
autoScalingGroup_serviceLinkedRoleARN = (AutoScalingGroup -> Maybe Text)
-> (AutoScalingGroup -> Maybe Text -> AutoScalingGroup)
-> Lens AutoScalingGroup AutoScalingGroup (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutoScalingGroup' {Maybe Text
serviceLinkedRoleARN :: Maybe Text
$sel:serviceLinkedRoleARN:AutoScalingGroup' :: AutoScalingGroup -> Maybe Text
serviceLinkedRoleARN} -> Maybe Text
serviceLinkedRoleARN) (\s :: AutoScalingGroup
s@AutoScalingGroup' {} Maybe Text
a -> AutoScalingGroup
s {$sel:serviceLinkedRoleARN:AutoScalingGroup' :: Maybe Text
serviceLinkedRoleARN = Maybe Text
a} :: AutoScalingGroup)

-- | Indicates whether newly launched instances are protected from
-- termination by Amazon EC2 Auto Scaling when scaling in.
autoScalingGroup_newInstancesProtectedFromScaleIn :: Lens.Lens' AutoScalingGroup (Prelude.Maybe Prelude.Bool)
autoScalingGroup_newInstancesProtectedFromScaleIn :: (Maybe Bool -> f (Maybe Bool))
-> AutoScalingGroup -> f AutoScalingGroup
autoScalingGroup_newInstancesProtectedFromScaleIn = (AutoScalingGroup -> Maybe Bool)
-> (AutoScalingGroup -> Maybe Bool -> AutoScalingGroup)
-> Lens AutoScalingGroup AutoScalingGroup (Maybe Bool) (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutoScalingGroup' {Maybe Bool
newInstancesProtectedFromScaleIn' :: Maybe Bool
$sel:newInstancesProtectedFromScaleIn':AutoScalingGroup' :: AutoScalingGroup -> Maybe Bool
newInstancesProtectedFromScaleIn'} -> Maybe Bool
newInstancesProtectedFromScaleIn') (\s :: AutoScalingGroup
s@AutoScalingGroup' {} Maybe Bool
a -> AutoScalingGroup
s {$sel:newInstancesProtectedFromScaleIn':AutoScalingGroup' :: Maybe Bool
newInstancesProtectedFromScaleIn' = Maybe Bool
a} :: AutoScalingGroup)

-- | One or more subnet IDs, if applicable, separated by commas.
autoScalingGroup_vPCZoneIdentifier :: Lens.Lens' AutoScalingGroup (Prelude.Maybe Prelude.Text)
autoScalingGroup_vPCZoneIdentifier :: (Maybe Text -> f (Maybe Text))
-> AutoScalingGroup -> f AutoScalingGroup
autoScalingGroup_vPCZoneIdentifier = (AutoScalingGroup -> Maybe Text)
-> (AutoScalingGroup -> Maybe Text -> AutoScalingGroup)
-> Lens AutoScalingGroup AutoScalingGroup (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutoScalingGroup' {Maybe Text
vPCZoneIdentifier :: Maybe Text
$sel:vPCZoneIdentifier:AutoScalingGroup' :: AutoScalingGroup -> Maybe Text
vPCZoneIdentifier} -> Maybe Text
vPCZoneIdentifier) (\s :: AutoScalingGroup
s@AutoScalingGroup' {} Maybe Text
a -> AutoScalingGroup
s {$sel:vPCZoneIdentifier:AutoScalingGroup' :: Maybe Text
vPCZoneIdentifier = Maybe Text
a} :: AutoScalingGroup)

-- | The Amazon Resource Names (ARN) of the target groups for your load
-- balancer.
autoScalingGroup_targetGroupARNs :: Lens.Lens' AutoScalingGroup (Prelude.Maybe [Prelude.Text])
autoScalingGroup_targetGroupARNs :: (Maybe [Text] -> f (Maybe [Text]))
-> AutoScalingGroup -> f AutoScalingGroup
autoScalingGroup_targetGroupARNs = (AutoScalingGroup -> Maybe [Text])
-> (AutoScalingGroup -> Maybe [Text] -> AutoScalingGroup)
-> Lens
     AutoScalingGroup AutoScalingGroup (Maybe [Text]) (Maybe [Text])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutoScalingGroup' {Maybe [Text]
targetGroupARNs :: Maybe [Text]
$sel:targetGroupARNs:AutoScalingGroup' :: AutoScalingGroup -> Maybe [Text]
targetGroupARNs} -> Maybe [Text]
targetGroupARNs) (\s :: AutoScalingGroup
s@AutoScalingGroup' {} Maybe [Text]
a -> AutoScalingGroup
s {$sel:targetGroupARNs:AutoScalingGroup' :: Maybe [Text]
targetGroupARNs = Maybe [Text]
a} :: AutoScalingGroup) ((Maybe [Text] -> f (Maybe [Text]))
 -> AutoScalingGroup -> f AutoScalingGroup)
-> ((Maybe [Text] -> f (Maybe [Text]))
    -> Maybe [Text] -> f (Maybe [Text]))
-> (Maybe [Text] -> f (Maybe [Text]))
-> AutoScalingGroup
-> f AutoScalingGroup
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Text] [Text] [Text] [Text]
-> Iso (Maybe [Text]) (Maybe [Text]) (Maybe [Text]) (Maybe [Text])
forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping AnIso [Text] [Text] [Text] [Text]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The maximum amount of time, in seconds, that an instance can be in
-- service.
--
-- Valid Range: Minimum value of 0.
autoScalingGroup_maxInstanceLifetime :: Lens.Lens' AutoScalingGroup (Prelude.Maybe Prelude.Int)
autoScalingGroup_maxInstanceLifetime :: (Maybe Int -> f (Maybe Int))
-> AutoScalingGroup -> f AutoScalingGroup
autoScalingGroup_maxInstanceLifetime = (AutoScalingGroup -> Maybe Int)
-> (AutoScalingGroup -> Maybe Int -> AutoScalingGroup)
-> Lens AutoScalingGroup AutoScalingGroup (Maybe Int) (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutoScalingGroup' {Maybe Int
maxInstanceLifetime :: Maybe Int
$sel:maxInstanceLifetime:AutoScalingGroup' :: AutoScalingGroup -> Maybe Int
maxInstanceLifetime} -> Maybe Int
maxInstanceLifetime) (\s :: AutoScalingGroup
s@AutoScalingGroup' {} Maybe Int
a -> AutoScalingGroup
s {$sel:maxInstanceLifetime:AutoScalingGroup' :: Maybe Int
maxInstanceLifetime = Maybe Int
a} :: AutoScalingGroup)

-- | The mixed instances policy for the group.
autoScalingGroup_mixedInstancesPolicy :: Lens.Lens' AutoScalingGroup (Prelude.Maybe MixedInstancesPolicy)
autoScalingGroup_mixedInstancesPolicy :: (Maybe MixedInstancesPolicy -> f (Maybe MixedInstancesPolicy))
-> AutoScalingGroup -> f AutoScalingGroup
autoScalingGroup_mixedInstancesPolicy = (AutoScalingGroup -> Maybe MixedInstancesPolicy)
-> (AutoScalingGroup
    -> Maybe MixedInstancesPolicy -> AutoScalingGroup)
-> Lens
     AutoScalingGroup
     AutoScalingGroup
     (Maybe MixedInstancesPolicy)
     (Maybe MixedInstancesPolicy)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutoScalingGroup' {Maybe MixedInstancesPolicy
mixedInstancesPolicy :: Maybe MixedInstancesPolicy
$sel:mixedInstancesPolicy:AutoScalingGroup' :: AutoScalingGroup -> Maybe MixedInstancesPolicy
mixedInstancesPolicy} -> Maybe MixedInstancesPolicy
mixedInstancesPolicy) (\s :: AutoScalingGroup
s@AutoScalingGroup' {} Maybe MixedInstancesPolicy
a -> AutoScalingGroup
s {$sel:mixedInstancesPolicy:AutoScalingGroup' :: Maybe MixedInstancesPolicy
mixedInstancesPolicy = Maybe MixedInstancesPolicy
a} :: AutoScalingGroup)

-- | The metrics enabled for the group.
autoScalingGroup_enabledMetrics :: Lens.Lens' AutoScalingGroup (Prelude.Maybe [EnabledMetric])
autoScalingGroup_enabledMetrics :: (Maybe [EnabledMetric] -> f (Maybe [EnabledMetric]))
-> AutoScalingGroup -> f AutoScalingGroup
autoScalingGroup_enabledMetrics = (AutoScalingGroup -> Maybe [EnabledMetric])
-> (AutoScalingGroup -> Maybe [EnabledMetric] -> AutoScalingGroup)
-> Lens
     AutoScalingGroup
     AutoScalingGroup
     (Maybe [EnabledMetric])
     (Maybe [EnabledMetric])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutoScalingGroup' {Maybe [EnabledMetric]
enabledMetrics :: Maybe [EnabledMetric]
$sel:enabledMetrics:AutoScalingGroup' :: AutoScalingGroup -> Maybe [EnabledMetric]
enabledMetrics} -> Maybe [EnabledMetric]
enabledMetrics) (\s :: AutoScalingGroup
s@AutoScalingGroup' {} Maybe [EnabledMetric]
a -> AutoScalingGroup
s {$sel:enabledMetrics:AutoScalingGroup' :: Maybe [EnabledMetric]
enabledMetrics = Maybe [EnabledMetric]
a} :: AutoScalingGroup) ((Maybe [EnabledMetric] -> f (Maybe [EnabledMetric]))
 -> AutoScalingGroup -> f AutoScalingGroup)
-> ((Maybe [EnabledMetric] -> f (Maybe [EnabledMetric]))
    -> Maybe [EnabledMetric] -> f (Maybe [EnabledMetric]))
-> (Maybe [EnabledMetric] -> f (Maybe [EnabledMetric]))
-> AutoScalingGroup
-> f AutoScalingGroup
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  [EnabledMetric] [EnabledMetric] [EnabledMetric] [EnabledMetric]
-> Iso
     (Maybe [EnabledMetric])
     (Maybe [EnabledMetric])
     (Maybe [EnabledMetric])
     (Maybe [EnabledMetric])
forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping AnIso
  [EnabledMetric] [EnabledMetric] [EnabledMetric] [EnabledMetric]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The name of the associated launch configuration.
autoScalingGroup_launchConfigurationName :: Lens.Lens' AutoScalingGroup (Prelude.Maybe Prelude.Text)
autoScalingGroup_launchConfigurationName :: (Maybe Text -> f (Maybe Text))
-> AutoScalingGroup -> f AutoScalingGroup
autoScalingGroup_launchConfigurationName = (AutoScalingGroup -> Maybe Text)
-> (AutoScalingGroup -> Maybe Text -> AutoScalingGroup)
-> Lens AutoScalingGroup AutoScalingGroup (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutoScalingGroup' {Maybe Text
launchConfigurationName :: Maybe Text
$sel:launchConfigurationName:AutoScalingGroup' :: AutoScalingGroup -> Maybe Text
launchConfigurationName} -> Maybe Text
launchConfigurationName) (\s :: AutoScalingGroup
s@AutoScalingGroup' {} Maybe Text
a -> AutoScalingGroup
s {$sel:launchConfigurationName:AutoScalingGroup' :: Maybe Text
launchConfigurationName = Maybe Text
a} :: AutoScalingGroup)

-- | The EC2 instances associated with the group.
autoScalingGroup_instances :: Lens.Lens' AutoScalingGroup (Prelude.Maybe [Instance])
autoScalingGroup_instances :: (Maybe [Instance] -> f (Maybe [Instance]))
-> AutoScalingGroup -> f AutoScalingGroup
autoScalingGroup_instances = (AutoScalingGroup -> Maybe [Instance])
-> (AutoScalingGroup -> Maybe [Instance] -> AutoScalingGroup)
-> Lens
     AutoScalingGroup
     AutoScalingGroup
     (Maybe [Instance])
     (Maybe [Instance])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutoScalingGroup' {Maybe [Instance]
instances :: Maybe [Instance]
$sel:instances:AutoScalingGroup' :: AutoScalingGroup -> Maybe [Instance]
instances} -> Maybe [Instance]
instances) (\s :: AutoScalingGroup
s@AutoScalingGroup' {} Maybe [Instance]
a -> AutoScalingGroup
s {$sel:instances:AutoScalingGroup' :: Maybe [Instance]
instances = Maybe [Instance]
a} :: AutoScalingGroup) ((Maybe [Instance] -> f (Maybe [Instance]))
 -> AutoScalingGroup -> f AutoScalingGroup)
-> ((Maybe [Instance] -> f (Maybe [Instance]))
    -> Maybe [Instance] -> f (Maybe [Instance]))
-> (Maybe [Instance] -> f (Maybe [Instance]))
-> AutoScalingGroup
-> f AutoScalingGroup
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Instance] [Instance] [Instance] [Instance]
-> Iso
     (Maybe [Instance])
     (Maybe [Instance])
     (Maybe [Instance])
     (Maybe [Instance])
forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping AnIso [Instance] [Instance] [Instance] [Instance]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The launch template for the group.
autoScalingGroup_launchTemplate :: Lens.Lens' AutoScalingGroup (Prelude.Maybe LaunchTemplateSpecification)
autoScalingGroup_launchTemplate :: (Maybe LaunchTemplateSpecification
 -> f (Maybe LaunchTemplateSpecification))
-> AutoScalingGroup -> f AutoScalingGroup
autoScalingGroup_launchTemplate = (AutoScalingGroup -> Maybe LaunchTemplateSpecification)
-> (AutoScalingGroup
    -> Maybe LaunchTemplateSpecification -> AutoScalingGroup)
-> Lens
     AutoScalingGroup
     AutoScalingGroup
     (Maybe LaunchTemplateSpecification)
     (Maybe LaunchTemplateSpecification)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutoScalingGroup' {Maybe LaunchTemplateSpecification
launchTemplate :: Maybe LaunchTemplateSpecification
$sel:launchTemplate:AutoScalingGroup' :: AutoScalingGroup -> Maybe LaunchTemplateSpecification
launchTemplate} -> Maybe LaunchTemplateSpecification
launchTemplate) (\s :: AutoScalingGroup
s@AutoScalingGroup' {} Maybe LaunchTemplateSpecification
a -> AutoScalingGroup
s {$sel:launchTemplate:AutoScalingGroup' :: Maybe LaunchTemplateSpecification
launchTemplate = Maybe LaunchTemplateSpecification
a} :: AutoScalingGroup)

-- | The warm pool for the group.
autoScalingGroup_warmPoolConfiguration :: Lens.Lens' AutoScalingGroup (Prelude.Maybe WarmPoolConfiguration)
autoScalingGroup_warmPoolConfiguration :: (Maybe WarmPoolConfiguration -> f (Maybe WarmPoolConfiguration))
-> AutoScalingGroup -> f AutoScalingGroup
autoScalingGroup_warmPoolConfiguration = (AutoScalingGroup -> Maybe WarmPoolConfiguration)
-> (AutoScalingGroup
    -> Maybe WarmPoolConfiguration -> AutoScalingGroup)
-> Lens
     AutoScalingGroup
     AutoScalingGroup
     (Maybe WarmPoolConfiguration)
     (Maybe WarmPoolConfiguration)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutoScalingGroup' {Maybe WarmPoolConfiguration
warmPoolConfiguration :: Maybe WarmPoolConfiguration
$sel:warmPoolConfiguration:AutoScalingGroup' :: AutoScalingGroup -> Maybe WarmPoolConfiguration
warmPoolConfiguration} -> Maybe WarmPoolConfiguration
warmPoolConfiguration) (\s :: AutoScalingGroup
s@AutoScalingGroup' {} Maybe WarmPoolConfiguration
a -> AutoScalingGroup
s {$sel:warmPoolConfiguration:AutoScalingGroup' :: Maybe WarmPoolConfiguration
warmPoolConfiguration = Maybe WarmPoolConfiguration
a} :: AutoScalingGroup)

-- | Indicates whether Capacity Rebalancing is enabled.
autoScalingGroup_capacityRebalance :: Lens.Lens' AutoScalingGroup (Prelude.Maybe Prelude.Bool)
autoScalingGroup_capacityRebalance :: (Maybe Bool -> f (Maybe Bool))
-> AutoScalingGroup -> f AutoScalingGroup
autoScalingGroup_capacityRebalance = (AutoScalingGroup -> Maybe Bool)
-> (AutoScalingGroup -> Maybe Bool -> AutoScalingGroup)
-> Lens AutoScalingGroup AutoScalingGroup (Maybe Bool) (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutoScalingGroup' {Maybe Bool
capacityRebalance :: Maybe Bool
$sel:capacityRebalance:AutoScalingGroup' :: AutoScalingGroup -> Maybe Bool
capacityRebalance} -> Maybe Bool
capacityRebalance) (\s :: AutoScalingGroup
s@AutoScalingGroup' {} Maybe Bool
a -> AutoScalingGroup
s {$sel:capacityRebalance:AutoScalingGroup' :: Maybe Bool
capacityRebalance = Maybe Bool
a} :: AutoScalingGroup)

-- | The Amazon Resource Name (ARN) of the Auto Scaling group.
autoScalingGroup_autoScalingGroupARN :: Lens.Lens' AutoScalingGroup (Prelude.Maybe Prelude.Text)
autoScalingGroup_autoScalingGroupARN :: (Maybe Text -> f (Maybe Text))
-> AutoScalingGroup -> f AutoScalingGroup
autoScalingGroup_autoScalingGroupARN = (AutoScalingGroup -> Maybe Text)
-> (AutoScalingGroup -> Maybe Text -> AutoScalingGroup)
-> Lens AutoScalingGroup AutoScalingGroup (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutoScalingGroup' {Maybe Text
autoScalingGroupARN :: Maybe Text
$sel:autoScalingGroupARN:AutoScalingGroup' :: AutoScalingGroup -> Maybe Text
autoScalingGroupARN} -> Maybe Text
autoScalingGroupARN) (\s :: AutoScalingGroup
s@AutoScalingGroup' {} Maybe Text
a -> AutoScalingGroup
s {$sel:autoScalingGroupARN:AutoScalingGroup' :: Maybe Text
autoScalingGroupARN = Maybe Text
a} :: AutoScalingGroup)

-- | The predicted capacity of the group when it has a predictive scaling
-- policy.
autoScalingGroup_predictedCapacity :: Lens.Lens' AutoScalingGroup (Prelude.Maybe Prelude.Int)
autoScalingGroup_predictedCapacity :: (Maybe Int -> f (Maybe Int))
-> AutoScalingGroup -> f AutoScalingGroup
autoScalingGroup_predictedCapacity = (AutoScalingGroup -> Maybe Int)
-> (AutoScalingGroup -> Maybe Int -> AutoScalingGroup)
-> Lens AutoScalingGroup AutoScalingGroup (Maybe Int) (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutoScalingGroup' {Maybe Int
predictedCapacity :: Maybe Int
$sel:predictedCapacity:AutoScalingGroup' :: AutoScalingGroup -> Maybe Int
predictedCapacity} -> Maybe Int
predictedCapacity) (\s :: AutoScalingGroup
s@AutoScalingGroup' {} Maybe Int
a -> AutoScalingGroup
s {$sel:predictedCapacity:AutoScalingGroup' :: Maybe Int
predictedCapacity = Maybe Int
a} :: AutoScalingGroup)

-- | The current size of the warm pool.
autoScalingGroup_warmPoolSize :: Lens.Lens' AutoScalingGroup (Prelude.Maybe Prelude.Int)
autoScalingGroup_warmPoolSize :: (Maybe Int -> f (Maybe Int))
-> AutoScalingGroup -> f AutoScalingGroup
autoScalingGroup_warmPoolSize = (AutoScalingGroup -> Maybe Int)
-> (AutoScalingGroup -> Maybe Int -> AutoScalingGroup)
-> Lens AutoScalingGroup AutoScalingGroup (Maybe Int) (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutoScalingGroup' {Maybe Int
warmPoolSize :: Maybe Int
$sel:warmPoolSize:AutoScalingGroup' :: AutoScalingGroup -> Maybe Int
warmPoolSize} -> Maybe Int
warmPoolSize) (\s :: AutoScalingGroup
s@AutoScalingGroup' {} Maybe Int
a -> AutoScalingGroup
s {$sel:warmPoolSize:AutoScalingGroup' :: Maybe Int
warmPoolSize = Maybe Int
a} :: AutoScalingGroup)

-- | The name of the placement group into which to launch your instances, if
-- any.
autoScalingGroup_placementGroup :: Lens.Lens' AutoScalingGroup (Prelude.Maybe Prelude.Text)
autoScalingGroup_placementGroup :: (Maybe Text -> f (Maybe Text))
-> AutoScalingGroup -> f AutoScalingGroup
autoScalingGroup_placementGroup = (AutoScalingGroup -> Maybe Text)
-> (AutoScalingGroup -> Maybe Text -> AutoScalingGroup)
-> Lens AutoScalingGroup AutoScalingGroup (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutoScalingGroup' {Maybe Text
placementGroup :: Maybe Text
$sel:placementGroup:AutoScalingGroup' :: AutoScalingGroup -> Maybe Text
placementGroup} -> Maybe Text
placementGroup) (\s :: AutoScalingGroup
s@AutoScalingGroup' {} Maybe Text
a -> AutoScalingGroup
s {$sel:placementGroup:AutoScalingGroup' :: Maybe Text
placementGroup = Maybe Text
a} :: AutoScalingGroup)

-- | The suspended processes associated with the group.
autoScalingGroup_suspendedProcesses :: Lens.Lens' AutoScalingGroup (Prelude.Maybe [SuspendedProcess])
autoScalingGroup_suspendedProcesses :: (Maybe [SuspendedProcess] -> f (Maybe [SuspendedProcess]))
-> AutoScalingGroup -> f AutoScalingGroup
autoScalingGroup_suspendedProcesses = (AutoScalingGroup -> Maybe [SuspendedProcess])
-> (AutoScalingGroup
    -> Maybe [SuspendedProcess] -> AutoScalingGroup)
-> Lens
     AutoScalingGroup
     AutoScalingGroup
     (Maybe [SuspendedProcess])
     (Maybe [SuspendedProcess])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutoScalingGroup' {Maybe [SuspendedProcess]
suspendedProcesses :: Maybe [SuspendedProcess]
$sel:suspendedProcesses:AutoScalingGroup' :: AutoScalingGroup -> Maybe [SuspendedProcess]
suspendedProcesses} -> Maybe [SuspendedProcess]
suspendedProcesses) (\s :: AutoScalingGroup
s@AutoScalingGroup' {} Maybe [SuspendedProcess]
a -> AutoScalingGroup
s {$sel:suspendedProcesses:AutoScalingGroup' :: Maybe [SuspendedProcess]
suspendedProcesses = Maybe [SuspendedProcess]
a} :: AutoScalingGroup) ((Maybe [SuspendedProcess] -> f (Maybe [SuspendedProcess]))
 -> AutoScalingGroup -> f AutoScalingGroup)
-> ((Maybe [SuspendedProcess] -> f (Maybe [SuspendedProcess]))
    -> Maybe [SuspendedProcess] -> f (Maybe [SuspendedProcess]))
-> (Maybe [SuspendedProcess] -> f (Maybe [SuspendedProcess]))
-> AutoScalingGroup
-> f AutoScalingGroup
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  [SuspendedProcess]
  [SuspendedProcess]
  [SuspendedProcess]
  [SuspendedProcess]
-> Iso
     (Maybe [SuspendedProcess])
     (Maybe [SuspendedProcess])
     (Maybe [SuspendedProcess])
     (Maybe [SuspendedProcess])
forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping AnIso
  [SuspendedProcess]
  [SuspendedProcess]
  [SuspendedProcess]
  [SuspendedProcess]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | One or more load balancers associated with the group.
autoScalingGroup_loadBalancerNames :: Lens.Lens' AutoScalingGroup (Prelude.Maybe [Prelude.Text])
autoScalingGroup_loadBalancerNames :: (Maybe [Text] -> f (Maybe [Text]))
-> AutoScalingGroup -> f AutoScalingGroup
autoScalingGroup_loadBalancerNames = (AutoScalingGroup -> Maybe [Text])
-> (AutoScalingGroup -> Maybe [Text] -> AutoScalingGroup)
-> Lens
     AutoScalingGroup AutoScalingGroup (Maybe [Text]) (Maybe [Text])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutoScalingGroup' {Maybe [Text]
loadBalancerNames :: Maybe [Text]
$sel:loadBalancerNames:AutoScalingGroup' :: AutoScalingGroup -> Maybe [Text]
loadBalancerNames} -> Maybe [Text]
loadBalancerNames) (\s :: AutoScalingGroup
s@AutoScalingGroup' {} Maybe [Text]
a -> AutoScalingGroup
s {$sel:loadBalancerNames:AutoScalingGroup' :: Maybe [Text]
loadBalancerNames = Maybe [Text]
a} :: AutoScalingGroup) ((Maybe [Text] -> f (Maybe [Text]))
 -> AutoScalingGroup -> f AutoScalingGroup)
-> ((Maybe [Text] -> f (Maybe [Text]))
    -> Maybe [Text] -> f (Maybe [Text]))
-> (Maybe [Text] -> f (Maybe [Text]))
-> AutoScalingGroup
-> f AutoScalingGroup
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Text] [Text] [Text] [Text]
-> Iso (Maybe [Text]) (Maybe [Text]) (Maybe [Text]) (Maybe [Text])
forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping AnIso [Text] [Text] [Text] [Text]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The tags for the group.
autoScalingGroup_tags :: Lens.Lens' AutoScalingGroup (Prelude.Maybe [TagDescription])
autoScalingGroup_tags :: (Maybe [TagDescription] -> f (Maybe [TagDescription]))
-> AutoScalingGroup -> f AutoScalingGroup
autoScalingGroup_tags = (AutoScalingGroup -> Maybe [TagDescription])
-> (AutoScalingGroup -> Maybe [TagDescription] -> AutoScalingGroup)
-> Lens
     AutoScalingGroup
     AutoScalingGroup
     (Maybe [TagDescription])
     (Maybe [TagDescription])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutoScalingGroup' {Maybe [TagDescription]
tags :: Maybe [TagDescription]
$sel:tags:AutoScalingGroup' :: AutoScalingGroup -> Maybe [TagDescription]
tags} -> Maybe [TagDescription]
tags) (\s :: AutoScalingGroup
s@AutoScalingGroup' {} Maybe [TagDescription]
a -> AutoScalingGroup
s {$sel:tags:AutoScalingGroup' :: Maybe [TagDescription]
tags = Maybe [TagDescription]
a} :: AutoScalingGroup) ((Maybe [TagDescription] -> f (Maybe [TagDescription]))
 -> AutoScalingGroup -> f AutoScalingGroup)
-> ((Maybe [TagDescription] -> f (Maybe [TagDescription]))
    -> Maybe [TagDescription] -> f (Maybe [TagDescription]))
-> (Maybe [TagDescription] -> f (Maybe [TagDescription]))
-> AutoScalingGroup
-> f AutoScalingGroup
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  [TagDescription] [TagDescription] [TagDescription] [TagDescription]
-> Iso
     (Maybe [TagDescription])
     (Maybe [TagDescription])
     (Maybe [TagDescription])
     (Maybe [TagDescription])
forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping AnIso
  [TagDescription] [TagDescription] [TagDescription] [TagDescription]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The name of the Auto Scaling group.
autoScalingGroup_autoScalingGroupName :: Lens.Lens' AutoScalingGroup Prelude.Text
autoScalingGroup_autoScalingGroupName :: (Text -> f Text) -> AutoScalingGroup -> f AutoScalingGroup
autoScalingGroup_autoScalingGroupName = (AutoScalingGroup -> Text)
-> (AutoScalingGroup -> Text -> AutoScalingGroup)
-> Lens AutoScalingGroup AutoScalingGroup Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutoScalingGroup' {Text
autoScalingGroupName :: Text
$sel:autoScalingGroupName:AutoScalingGroup' :: AutoScalingGroup -> Text
autoScalingGroupName} -> Text
autoScalingGroupName) (\s :: AutoScalingGroup
s@AutoScalingGroup' {} Text
a -> AutoScalingGroup
s {$sel:autoScalingGroupName:AutoScalingGroup' :: Text
autoScalingGroupName = Text
a} :: AutoScalingGroup)

-- | The minimum size of the group.
autoScalingGroup_minSize :: Lens.Lens' AutoScalingGroup Prelude.Int
autoScalingGroup_minSize :: (Int -> f Int) -> AutoScalingGroup -> f AutoScalingGroup
autoScalingGroup_minSize = (AutoScalingGroup -> Int)
-> (AutoScalingGroup -> Int -> AutoScalingGroup)
-> Lens AutoScalingGroup AutoScalingGroup Int Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutoScalingGroup' {Int
minSize :: Int
$sel:minSize:AutoScalingGroup' :: AutoScalingGroup -> Int
minSize} -> Int
minSize) (\s :: AutoScalingGroup
s@AutoScalingGroup' {} Int
a -> AutoScalingGroup
s {$sel:minSize:AutoScalingGroup' :: Int
minSize = Int
a} :: AutoScalingGroup)

-- | The maximum size of the group.
autoScalingGroup_maxSize :: Lens.Lens' AutoScalingGroup Prelude.Int
autoScalingGroup_maxSize :: (Int -> f Int) -> AutoScalingGroup -> f AutoScalingGroup
autoScalingGroup_maxSize = (AutoScalingGroup -> Int)
-> (AutoScalingGroup -> Int -> AutoScalingGroup)
-> Lens AutoScalingGroup AutoScalingGroup Int Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutoScalingGroup' {Int
maxSize :: Int
$sel:maxSize:AutoScalingGroup' :: AutoScalingGroup -> Int
maxSize} -> Int
maxSize) (\s :: AutoScalingGroup
s@AutoScalingGroup' {} Int
a -> AutoScalingGroup
s {$sel:maxSize:AutoScalingGroup' :: Int
maxSize = Int
a} :: AutoScalingGroup)

-- | The desired size of the group.
autoScalingGroup_desiredCapacity :: Lens.Lens' AutoScalingGroup Prelude.Int
autoScalingGroup_desiredCapacity :: (Int -> f Int) -> AutoScalingGroup -> f AutoScalingGroup
autoScalingGroup_desiredCapacity = (AutoScalingGroup -> Int)
-> (AutoScalingGroup -> Int -> AutoScalingGroup)
-> Lens AutoScalingGroup AutoScalingGroup Int Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutoScalingGroup' {Int
desiredCapacity :: Int
$sel:desiredCapacity:AutoScalingGroup' :: AutoScalingGroup -> Int
desiredCapacity} -> Int
desiredCapacity) (\s :: AutoScalingGroup
s@AutoScalingGroup' {} Int
a -> AutoScalingGroup
s {$sel:desiredCapacity:AutoScalingGroup' :: Int
desiredCapacity = Int
a} :: AutoScalingGroup)

-- | The duration of the default cooldown period, in seconds.
autoScalingGroup_defaultCooldown :: Lens.Lens' AutoScalingGroup Prelude.Int
autoScalingGroup_defaultCooldown :: (Int -> f Int) -> AutoScalingGroup -> f AutoScalingGroup
autoScalingGroup_defaultCooldown = (AutoScalingGroup -> Int)
-> (AutoScalingGroup -> Int -> AutoScalingGroup)
-> Lens AutoScalingGroup AutoScalingGroup Int Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutoScalingGroup' {Int
defaultCooldown :: Int
$sel:defaultCooldown:AutoScalingGroup' :: AutoScalingGroup -> Int
defaultCooldown} -> Int
defaultCooldown) (\s :: AutoScalingGroup
s@AutoScalingGroup' {} Int
a -> AutoScalingGroup
s {$sel:defaultCooldown:AutoScalingGroup' :: Int
defaultCooldown = Int
a} :: AutoScalingGroup)

-- | One or more Availability Zones for the group.
autoScalingGroup_availabilityZones :: Lens.Lens' AutoScalingGroup [Prelude.Text]
autoScalingGroup_availabilityZones :: ([Text] -> f [Text]) -> AutoScalingGroup -> f AutoScalingGroup
autoScalingGroup_availabilityZones = (AutoScalingGroup -> [Text])
-> (AutoScalingGroup -> [Text] -> AutoScalingGroup)
-> Lens AutoScalingGroup AutoScalingGroup [Text] [Text]
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutoScalingGroup' {[Text]
availabilityZones :: [Text]
$sel:availabilityZones:AutoScalingGroup' :: AutoScalingGroup -> [Text]
availabilityZones} -> [Text]
availabilityZones) (\s :: AutoScalingGroup
s@AutoScalingGroup' {} [Text]
a -> AutoScalingGroup
s {$sel:availabilityZones:AutoScalingGroup' :: [Text]
availabilityZones = [Text]
a} :: AutoScalingGroup) (([Text] -> f [Text]) -> AutoScalingGroup -> f AutoScalingGroup)
-> (([Text] -> f [Text]) -> [Text] -> f [Text])
-> ([Text] -> f [Text])
-> AutoScalingGroup
-> f AutoScalingGroup
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. ([Text] -> f [Text]) -> [Text] -> f [Text]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The service to use for the health checks. The valid values are @EC2@ and
-- @ELB@. If you configure an Auto Scaling group to use @ELB@ health
-- checks, it considers the instance unhealthy if it fails either the EC2
-- status checks or the load balancer health checks.
autoScalingGroup_healthCheckType :: Lens.Lens' AutoScalingGroup Prelude.Text
autoScalingGroup_healthCheckType :: (Text -> f Text) -> AutoScalingGroup -> f AutoScalingGroup
autoScalingGroup_healthCheckType = (AutoScalingGroup -> Text)
-> (AutoScalingGroup -> Text -> AutoScalingGroup)
-> Lens AutoScalingGroup AutoScalingGroup Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutoScalingGroup' {Text
healthCheckType :: Text
$sel:healthCheckType:AutoScalingGroup' :: AutoScalingGroup -> Text
healthCheckType} -> Text
healthCheckType) (\s :: AutoScalingGroup
s@AutoScalingGroup' {} Text
a -> AutoScalingGroup
s {$sel:healthCheckType:AutoScalingGroup' :: Text
healthCheckType = Text
a} :: AutoScalingGroup)

-- | The date and time the group was created.
autoScalingGroup_createdTime :: Lens.Lens' AutoScalingGroup Prelude.UTCTime
autoScalingGroup_createdTime :: (UTCTime -> f UTCTime) -> AutoScalingGroup -> f AutoScalingGroup
autoScalingGroup_createdTime = (AutoScalingGroup -> ISO8601)
-> (AutoScalingGroup -> ISO8601 -> AutoScalingGroup)
-> Lens AutoScalingGroup AutoScalingGroup ISO8601 ISO8601
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutoScalingGroup' {ISO8601
createdTime :: ISO8601
$sel:createdTime:AutoScalingGroup' :: AutoScalingGroup -> ISO8601
createdTime} -> ISO8601
createdTime) (\s :: AutoScalingGroup
s@AutoScalingGroup' {} ISO8601
a -> AutoScalingGroup
s {$sel:createdTime:AutoScalingGroup' :: ISO8601
createdTime = ISO8601
a} :: AutoScalingGroup) ((ISO8601 -> f ISO8601) -> AutoScalingGroup -> f AutoScalingGroup)
-> ((UTCTime -> f UTCTime) -> ISO8601 -> f ISO8601)
-> (UTCTime -> f UTCTime)
-> AutoScalingGroup
-> f AutoScalingGroup
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. (UTCTime -> f UTCTime) -> ISO8601 -> f ISO8601
forall (a :: Format). Iso' (Time a) UTCTime
Core._Time

instance Core.FromXML AutoScalingGroup where
  parseXML :: [Node] -> Either String AutoScalingGroup
parseXML [Node]
x =
    Maybe Text
-> Maybe Text
-> Maybe [Text]
-> Maybe Int
-> Maybe Text
-> Maybe Bool
-> Maybe Text
-> Maybe [Text]
-> Maybe Int
-> Maybe MixedInstancesPolicy
-> Maybe [EnabledMetric]
-> Maybe Text
-> Maybe [Instance]
-> Maybe LaunchTemplateSpecification
-> Maybe WarmPoolConfiguration
-> Maybe Bool
-> Maybe Text
-> Maybe Int
-> Maybe Int
-> Maybe Text
-> Maybe [SuspendedProcess]
-> Maybe [Text]
-> Maybe [TagDescription]
-> Text
-> Int
-> Int
-> Int
-> Int
-> [Text]
-> Text
-> ISO8601
-> AutoScalingGroup
AutoScalingGroup'
      (Maybe Text
 -> Maybe Text
 -> Maybe [Text]
 -> Maybe Int
 -> Maybe Text
 -> Maybe Bool
 -> Maybe Text
 -> Maybe [Text]
 -> Maybe Int
 -> Maybe MixedInstancesPolicy
 -> Maybe [EnabledMetric]
 -> Maybe Text
 -> Maybe [Instance]
 -> Maybe LaunchTemplateSpecification
 -> Maybe WarmPoolConfiguration
 -> Maybe Bool
 -> Maybe Text
 -> Maybe Int
 -> Maybe Int
 -> Maybe Text
 -> Maybe [SuspendedProcess]
 -> Maybe [Text]
 -> Maybe [TagDescription]
 -> Text
 -> Int
 -> Int
 -> Int
 -> Int
 -> [Text]
 -> Text
 -> ISO8601
 -> AutoScalingGroup)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Text
      -> Maybe [Text]
      -> Maybe Int
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe [Text]
      -> Maybe Int
      -> Maybe MixedInstancesPolicy
      -> Maybe [EnabledMetric]
      -> Maybe Text
      -> Maybe [Instance]
      -> Maybe LaunchTemplateSpecification
      -> Maybe WarmPoolConfiguration
      -> Maybe Bool
      -> Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe [SuspendedProcess]
      -> Maybe [Text]
      -> Maybe [TagDescription]
      -> Text
      -> Int
      -> Int
      -> Int
      -> Int
      -> [Text]
      -> Text
      -> ISO8601
      -> AutoScalingGroup)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> ([Node]
x [Node] -> Text -> Either String (Maybe Text)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"Status")
      Either
  String
  (Maybe Text
   -> Maybe [Text]
   -> Maybe Int
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe [Text]
   -> Maybe Int
   -> Maybe MixedInstancesPolicy
   -> Maybe [EnabledMetric]
   -> Maybe Text
   -> Maybe [Instance]
   -> Maybe LaunchTemplateSpecification
   -> Maybe WarmPoolConfiguration
   -> Maybe Bool
   -> Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe [SuspendedProcess]
   -> Maybe [Text]
   -> Maybe [TagDescription]
   -> Text
   -> Int
   -> Int
   -> Int
   -> Int
   -> [Text]
   -> Text
   -> ISO8601
   -> AutoScalingGroup)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe [Text]
      -> Maybe Int
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe [Text]
      -> Maybe Int
      -> Maybe MixedInstancesPolicy
      -> Maybe [EnabledMetric]
      -> Maybe Text
      -> Maybe [Instance]
      -> Maybe LaunchTemplateSpecification
      -> Maybe WarmPoolConfiguration
      -> Maybe Bool
      -> Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe [SuspendedProcess]
      -> Maybe [Text]
      -> Maybe [TagDescription]
      -> Text
      -> Int
      -> Int
      -> Int
      -> Int
      -> [Text]
      -> Text
      -> ISO8601
      -> AutoScalingGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Text)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"Context")
      Either
  String
  (Maybe [Text]
   -> Maybe Int
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe [Text]
   -> Maybe Int
   -> Maybe MixedInstancesPolicy
   -> Maybe [EnabledMetric]
   -> Maybe Text
   -> Maybe [Instance]
   -> Maybe LaunchTemplateSpecification
   -> Maybe WarmPoolConfiguration
   -> Maybe Bool
   -> Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe [SuspendedProcess]
   -> Maybe [Text]
   -> Maybe [TagDescription]
   -> Text
   -> Int
   -> Int
   -> Int
   -> Int
   -> [Text]
   -> Text
   -> ISO8601
   -> AutoScalingGroup)
-> Either String (Maybe [Text])
-> Either
     String
     (Maybe Int
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe [Text]
      -> Maybe Int
      -> Maybe MixedInstancesPolicy
      -> Maybe [EnabledMetric]
      -> Maybe Text
      -> Maybe [Instance]
      -> Maybe LaunchTemplateSpecification
      -> Maybe WarmPoolConfiguration
      -> Maybe Bool
      -> Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe [SuspendedProcess]
      -> Maybe [Text]
      -> Maybe [TagDescription]
      -> Text
      -> Int
      -> Int
      -> Int
      -> Int
      -> [Text]
      -> Text
      -> ISO8601
      -> AutoScalingGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( [Node]
x [Node] -> Text -> Either String (Maybe [Node])
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"TerminationPolicies"
                      Either String (Maybe [Node]) -> [Node] -> Either String [Node]
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ [Node]
forall a. Monoid a => a
Prelude.mempty
                      Either String [Node]
-> ([Node] -> Either String (Maybe [Text]))
-> Either String (Maybe [Text])
forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b
Prelude.>>= ([Node] -> Either String [Text])
-> [Node] -> Either String (Maybe [Text])
forall (f :: * -> *) a b.
Applicative f =>
([a] -> f b) -> [a] -> f (Maybe b)
Core.may (Text -> [Node] -> Either String [Text]
forall a. FromXML a => Text -> [Node] -> Either String [a]
Core.parseXMLList Text
"member")
                  )
      Either
  String
  (Maybe Int
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe [Text]
   -> Maybe Int
   -> Maybe MixedInstancesPolicy
   -> Maybe [EnabledMetric]
   -> Maybe Text
   -> Maybe [Instance]
   -> Maybe LaunchTemplateSpecification
   -> Maybe WarmPoolConfiguration
   -> Maybe Bool
   -> Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe [SuspendedProcess]
   -> Maybe [Text]
   -> Maybe [TagDescription]
   -> Text
   -> Int
   -> Int
   -> Int
   -> Int
   -> [Text]
   -> Text
   -> ISO8601
   -> AutoScalingGroup)
-> Either String (Maybe Int)
-> Either
     String
     (Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe [Text]
      -> Maybe Int
      -> Maybe MixedInstancesPolicy
      -> Maybe [EnabledMetric]
      -> Maybe Text
      -> Maybe [Instance]
      -> Maybe LaunchTemplateSpecification
      -> Maybe WarmPoolConfiguration
      -> Maybe Bool
      -> Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe [SuspendedProcess]
      -> Maybe [Text]
      -> Maybe [TagDescription]
      -> Text
      -> Int
      -> Int
      -> Int
      -> Int
      -> [Text]
      -> Text
      -> ISO8601
      -> AutoScalingGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Int)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"HealthCheckGracePeriod")
      Either
  String
  (Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe [Text]
   -> Maybe Int
   -> Maybe MixedInstancesPolicy
   -> Maybe [EnabledMetric]
   -> Maybe Text
   -> Maybe [Instance]
   -> Maybe LaunchTemplateSpecification
   -> Maybe WarmPoolConfiguration
   -> Maybe Bool
   -> Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe [SuspendedProcess]
   -> Maybe [Text]
   -> Maybe [TagDescription]
   -> Text
   -> Int
   -> Int
   -> Int
   -> Int
   -> [Text]
   -> Text
   -> ISO8601
   -> AutoScalingGroup)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Bool
      -> Maybe Text
      -> Maybe [Text]
      -> Maybe Int
      -> Maybe MixedInstancesPolicy
      -> Maybe [EnabledMetric]
      -> Maybe Text
      -> Maybe [Instance]
      -> Maybe LaunchTemplateSpecification
      -> Maybe WarmPoolConfiguration
      -> Maybe Bool
      -> Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe [SuspendedProcess]
      -> Maybe [Text]
      -> Maybe [TagDescription]
      -> Text
      -> Int
      -> Int
      -> Int
      -> Int
      -> [Text]
      -> Text
      -> ISO8601
      -> AutoScalingGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Text)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"ServiceLinkedRoleARN")
      Either
  String
  (Maybe Bool
   -> Maybe Text
   -> Maybe [Text]
   -> Maybe Int
   -> Maybe MixedInstancesPolicy
   -> Maybe [EnabledMetric]
   -> Maybe Text
   -> Maybe [Instance]
   -> Maybe LaunchTemplateSpecification
   -> Maybe WarmPoolConfiguration
   -> Maybe Bool
   -> Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe [SuspendedProcess]
   -> Maybe [Text]
   -> Maybe [TagDescription]
   -> Text
   -> Int
   -> Int
   -> Int
   -> Int
   -> [Text]
   -> Text
   -> ISO8601
   -> AutoScalingGroup)
-> Either String (Maybe Bool)
-> Either
     String
     (Maybe Text
      -> Maybe [Text]
      -> Maybe Int
      -> Maybe MixedInstancesPolicy
      -> Maybe [EnabledMetric]
      -> Maybe Text
      -> Maybe [Instance]
      -> Maybe LaunchTemplateSpecification
      -> Maybe WarmPoolConfiguration
      -> Maybe Bool
      -> Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe [SuspendedProcess]
      -> Maybe [Text]
      -> Maybe [TagDescription]
      -> Text
      -> Int
      -> Int
      -> Int
      -> Int
      -> [Text]
      -> Text
      -> ISO8601
      -> AutoScalingGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Bool)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"NewInstancesProtectedFromScaleIn")
      Either
  String
  (Maybe Text
   -> Maybe [Text]
   -> Maybe Int
   -> Maybe MixedInstancesPolicy
   -> Maybe [EnabledMetric]
   -> Maybe Text
   -> Maybe [Instance]
   -> Maybe LaunchTemplateSpecification
   -> Maybe WarmPoolConfiguration
   -> Maybe Bool
   -> Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe [SuspendedProcess]
   -> Maybe [Text]
   -> Maybe [TagDescription]
   -> Text
   -> Int
   -> Int
   -> Int
   -> Int
   -> [Text]
   -> Text
   -> ISO8601
   -> AutoScalingGroup)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe [Text]
      -> Maybe Int
      -> Maybe MixedInstancesPolicy
      -> Maybe [EnabledMetric]
      -> Maybe Text
      -> Maybe [Instance]
      -> Maybe LaunchTemplateSpecification
      -> Maybe WarmPoolConfiguration
      -> Maybe Bool
      -> Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe [SuspendedProcess]
      -> Maybe [Text]
      -> Maybe [TagDescription]
      -> Text
      -> Int
      -> Int
      -> Int
      -> Int
      -> [Text]
      -> Text
      -> ISO8601
      -> AutoScalingGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Text)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"VPCZoneIdentifier")
      Either
  String
  (Maybe [Text]
   -> Maybe Int
   -> Maybe MixedInstancesPolicy
   -> Maybe [EnabledMetric]
   -> Maybe Text
   -> Maybe [Instance]
   -> Maybe LaunchTemplateSpecification
   -> Maybe WarmPoolConfiguration
   -> Maybe Bool
   -> Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe [SuspendedProcess]
   -> Maybe [Text]
   -> Maybe [TagDescription]
   -> Text
   -> Int
   -> Int
   -> Int
   -> Int
   -> [Text]
   -> Text
   -> ISO8601
   -> AutoScalingGroup)
-> Either String (Maybe [Text])
-> Either
     String
     (Maybe Int
      -> Maybe MixedInstancesPolicy
      -> Maybe [EnabledMetric]
      -> Maybe Text
      -> Maybe [Instance]
      -> Maybe LaunchTemplateSpecification
      -> Maybe WarmPoolConfiguration
      -> Maybe Bool
      -> Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe [SuspendedProcess]
      -> Maybe [Text]
      -> Maybe [TagDescription]
      -> Text
      -> Int
      -> Int
      -> Int
      -> Int
      -> [Text]
      -> Text
      -> ISO8601
      -> AutoScalingGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( [Node]
x [Node] -> Text -> Either String (Maybe [Node])
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"TargetGroupARNs" Either String (Maybe [Node]) -> [Node] -> Either String [Node]
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ [Node]
forall a. Monoid a => a
Prelude.mempty
                      Either String [Node]
-> ([Node] -> Either String (Maybe [Text]))
-> Either String (Maybe [Text])
forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b
Prelude.>>= ([Node] -> Either String [Text])
-> [Node] -> Either String (Maybe [Text])
forall (f :: * -> *) a b.
Applicative f =>
([a] -> f b) -> [a] -> f (Maybe b)
Core.may (Text -> [Node] -> Either String [Text]
forall a. FromXML a => Text -> [Node] -> Either String [a]
Core.parseXMLList Text
"member")
                  )
      Either
  String
  (Maybe Int
   -> Maybe MixedInstancesPolicy
   -> Maybe [EnabledMetric]
   -> Maybe Text
   -> Maybe [Instance]
   -> Maybe LaunchTemplateSpecification
   -> Maybe WarmPoolConfiguration
   -> Maybe Bool
   -> Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe [SuspendedProcess]
   -> Maybe [Text]
   -> Maybe [TagDescription]
   -> Text
   -> Int
   -> Int
   -> Int
   -> Int
   -> [Text]
   -> Text
   -> ISO8601
   -> AutoScalingGroup)
-> Either String (Maybe Int)
-> Either
     String
     (Maybe MixedInstancesPolicy
      -> Maybe [EnabledMetric]
      -> Maybe Text
      -> Maybe [Instance]
      -> Maybe LaunchTemplateSpecification
      -> Maybe WarmPoolConfiguration
      -> Maybe Bool
      -> Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe [SuspendedProcess]
      -> Maybe [Text]
      -> Maybe [TagDescription]
      -> Text
      -> Int
      -> Int
      -> Int
      -> Int
      -> [Text]
      -> Text
      -> ISO8601
      -> AutoScalingGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Int)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"MaxInstanceLifetime")
      Either
  String
  (Maybe MixedInstancesPolicy
   -> Maybe [EnabledMetric]
   -> Maybe Text
   -> Maybe [Instance]
   -> Maybe LaunchTemplateSpecification
   -> Maybe WarmPoolConfiguration
   -> Maybe Bool
   -> Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe [SuspendedProcess]
   -> Maybe [Text]
   -> Maybe [TagDescription]
   -> Text
   -> Int
   -> Int
   -> Int
   -> Int
   -> [Text]
   -> Text
   -> ISO8601
   -> AutoScalingGroup)
-> Either String (Maybe MixedInstancesPolicy)
-> Either
     String
     (Maybe [EnabledMetric]
      -> Maybe Text
      -> Maybe [Instance]
      -> Maybe LaunchTemplateSpecification
      -> Maybe WarmPoolConfiguration
      -> Maybe Bool
      -> Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe [SuspendedProcess]
      -> Maybe [Text]
      -> Maybe [TagDescription]
      -> Text
      -> Int
      -> Int
      -> Int
      -> Int
      -> [Text]
      -> Text
      -> ISO8601
      -> AutoScalingGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe MixedInstancesPolicy)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"MixedInstancesPolicy")
      Either
  String
  (Maybe [EnabledMetric]
   -> Maybe Text
   -> Maybe [Instance]
   -> Maybe LaunchTemplateSpecification
   -> Maybe WarmPoolConfiguration
   -> Maybe Bool
   -> Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe [SuspendedProcess]
   -> Maybe [Text]
   -> Maybe [TagDescription]
   -> Text
   -> Int
   -> Int
   -> Int
   -> Int
   -> [Text]
   -> Text
   -> ISO8601
   -> AutoScalingGroup)
-> Either String (Maybe [EnabledMetric])
-> Either
     String
     (Maybe Text
      -> Maybe [Instance]
      -> Maybe LaunchTemplateSpecification
      -> Maybe WarmPoolConfiguration
      -> Maybe Bool
      -> Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe [SuspendedProcess]
      -> Maybe [Text]
      -> Maybe [TagDescription]
      -> Text
      -> Int
      -> Int
      -> Int
      -> Int
      -> [Text]
      -> Text
      -> ISO8601
      -> AutoScalingGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( [Node]
x [Node] -> Text -> Either String (Maybe [Node])
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"EnabledMetrics" Either String (Maybe [Node]) -> [Node] -> Either String [Node]
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ [Node]
forall a. Monoid a => a
Prelude.mempty
                      Either String [Node]
-> ([Node] -> Either String (Maybe [EnabledMetric]))
-> Either String (Maybe [EnabledMetric])
forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b
Prelude.>>= ([Node] -> Either String [EnabledMetric])
-> [Node] -> Either String (Maybe [EnabledMetric])
forall (f :: * -> *) a b.
Applicative f =>
([a] -> f b) -> [a] -> f (Maybe b)
Core.may (Text -> [Node] -> Either String [EnabledMetric]
forall a. FromXML a => Text -> [Node] -> Either String [a]
Core.parseXMLList Text
"member")
                  )
      Either
  String
  (Maybe Text
   -> Maybe [Instance]
   -> Maybe LaunchTemplateSpecification
   -> Maybe WarmPoolConfiguration
   -> Maybe Bool
   -> Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe [SuspendedProcess]
   -> Maybe [Text]
   -> Maybe [TagDescription]
   -> Text
   -> Int
   -> Int
   -> Int
   -> Int
   -> [Text]
   -> Text
   -> ISO8601
   -> AutoScalingGroup)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe [Instance]
      -> Maybe LaunchTemplateSpecification
      -> Maybe WarmPoolConfiguration
      -> Maybe Bool
      -> Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe [SuspendedProcess]
      -> Maybe [Text]
      -> Maybe [TagDescription]
      -> Text
      -> Int
      -> Int
      -> Int
      -> Int
      -> [Text]
      -> Text
      -> ISO8601
      -> AutoScalingGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Text)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"LaunchConfigurationName")
      Either
  String
  (Maybe [Instance]
   -> Maybe LaunchTemplateSpecification
   -> Maybe WarmPoolConfiguration
   -> Maybe Bool
   -> Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe [SuspendedProcess]
   -> Maybe [Text]
   -> Maybe [TagDescription]
   -> Text
   -> Int
   -> Int
   -> Int
   -> Int
   -> [Text]
   -> Text
   -> ISO8601
   -> AutoScalingGroup)
-> Either String (Maybe [Instance])
-> Either
     String
     (Maybe LaunchTemplateSpecification
      -> Maybe WarmPoolConfiguration
      -> Maybe Bool
      -> Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe [SuspendedProcess]
      -> Maybe [Text]
      -> Maybe [TagDescription]
      -> Text
      -> Int
      -> Int
      -> Int
      -> Int
      -> [Text]
      -> Text
      -> ISO8601
      -> AutoScalingGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( [Node]
x [Node] -> Text -> Either String (Maybe [Node])
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"Instances" Either String (Maybe [Node]) -> [Node] -> Either String [Node]
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ [Node]
forall a. Monoid a => a
Prelude.mempty
                      Either String [Node]
-> ([Node] -> Either String (Maybe [Instance]))
-> Either String (Maybe [Instance])
forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b
Prelude.>>= ([Node] -> Either String [Instance])
-> [Node] -> Either String (Maybe [Instance])
forall (f :: * -> *) a b.
Applicative f =>
([a] -> f b) -> [a] -> f (Maybe b)
Core.may (Text -> [Node] -> Either String [Instance]
forall a. FromXML a => Text -> [Node] -> Either String [a]
Core.parseXMLList Text
"member")
                  )
      Either
  String
  (Maybe LaunchTemplateSpecification
   -> Maybe WarmPoolConfiguration
   -> Maybe Bool
   -> Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe [SuspendedProcess]
   -> Maybe [Text]
   -> Maybe [TagDescription]
   -> Text
   -> Int
   -> Int
   -> Int
   -> Int
   -> [Text]
   -> Text
   -> ISO8601
   -> AutoScalingGroup)
-> Either String (Maybe LaunchTemplateSpecification)
-> Either
     String
     (Maybe WarmPoolConfiguration
      -> Maybe Bool
      -> Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe [SuspendedProcess]
      -> Maybe [Text]
      -> Maybe [TagDescription]
      -> Text
      -> Int
      -> Int
      -> Int
      -> Int
      -> [Text]
      -> Text
      -> ISO8601
      -> AutoScalingGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe LaunchTemplateSpecification)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"LaunchTemplate")
      Either
  String
  (Maybe WarmPoolConfiguration
   -> Maybe Bool
   -> Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe [SuspendedProcess]
   -> Maybe [Text]
   -> Maybe [TagDescription]
   -> Text
   -> Int
   -> Int
   -> Int
   -> Int
   -> [Text]
   -> Text
   -> ISO8601
   -> AutoScalingGroup)
-> Either String (Maybe WarmPoolConfiguration)
-> Either
     String
     (Maybe Bool
      -> Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe [SuspendedProcess]
      -> Maybe [Text]
      -> Maybe [TagDescription]
      -> Text
      -> Int
      -> Int
      -> Int
      -> Int
      -> [Text]
      -> Text
      -> ISO8601
      -> AutoScalingGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe WarmPoolConfiguration)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"WarmPoolConfiguration")
      Either
  String
  (Maybe Bool
   -> Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe [SuspendedProcess]
   -> Maybe [Text]
   -> Maybe [TagDescription]
   -> Text
   -> Int
   -> Int
   -> Int
   -> Int
   -> [Text]
   -> Text
   -> ISO8601
   -> AutoScalingGroup)
-> Either String (Maybe Bool)
-> Either
     String
     (Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe [SuspendedProcess]
      -> Maybe [Text]
      -> Maybe [TagDescription]
      -> Text
      -> Int
      -> Int
      -> Int
      -> Int
      -> [Text]
      -> Text
      -> ISO8601
      -> AutoScalingGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Bool)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"CapacityRebalance")
      Either
  String
  (Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe [SuspendedProcess]
   -> Maybe [Text]
   -> Maybe [TagDescription]
   -> Text
   -> Int
   -> Int
   -> Int
   -> Int
   -> [Text]
   -> Text
   -> ISO8601
   -> AutoScalingGroup)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe [SuspendedProcess]
      -> Maybe [Text]
      -> Maybe [TagDescription]
      -> Text
      -> Int
      -> Int
      -> Int
      -> Int
      -> [Text]
      -> Text
      -> ISO8601
      -> AutoScalingGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Text)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"AutoScalingGroupARN")
      Either
  String
  (Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe [SuspendedProcess]
   -> Maybe [Text]
   -> Maybe [TagDescription]
   -> Text
   -> Int
   -> Int
   -> Int
   -> Int
   -> [Text]
   -> Text
   -> ISO8601
   -> AutoScalingGroup)
-> Either String (Maybe Int)
-> Either
     String
     (Maybe Int
      -> Maybe Text
      -> Maybe [SuspendedProcess]
      -> Maybe [Text]
      -> Maybe [TagDescription]
      -> Text
      -> Int
      -> Int
      -> Int
      -> Int
      -> [Text]
      -> Text
      -> ISO8601
      -> AutoScalingGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Int)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"PredictedCapacity")
      Either
  String
  (Maybe Int
   -> Maybe Text
   -> Maybe [SuspendedProcess]
   -> Maybe [Text]
   -> Maybe [TagDescription]
   -> Text
   -> Int
   -> Int
   -> Int
   -> Int
   -> [Text]
   -> Text
   -> ISO8601
   -> AutoScalingGroup)
-> Either String (Maybe Int)
-> Either
     String
     (Maybe Text
      -> Maybe [SuspendedProcess]
      -> Maybe [Text]
      -> Maybe [TagDescription]
      -> Text
      -> Int
      -> Int
      -> Int
      -> Int
      -> [Text]
      -> Text
      -> ISO8601
      -> AutoScalingGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Int)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"WarmPoolSize")
      Either
  String
  (Maybe Text
   -> Maybe [SuspendedProcess]
   -> Maybe [Text]
   -> Maybe [TagDescription]
   -> Text
   -> Int
   -> Int
   -> Int
   -> Int
   -> [Text]
   -> Text
   -> ISO8601
   -> AutoScalingGroup)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe [SuspendedProcess]
      -> Maybe [Text]
      -> Maybe [TagDescription]
      -> Text
      -> Int
      -> Int
      -> Int
      -> Int
      -> [Text]
      -> Text
      -> ISO8601
      -> AutoScalingGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Text)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"PlacementGroup")
      Either
  String
  (Maybe [SuspendedProcess]
   -> Maybe [Text]
   -> Maybe [TagDescription]
   -> Text
   -> Int
   -> Int
   -> Int
   -> Int
   -> [Text]
   -> Text
   -> ISO8601
   -> AutoScalingGroup)
-> Either String (Maybe [SuspendedProcess])
-> Either
     String
     (Maybe [Text]
      -> Maybe [TagDescription]
      -> Text
      -> Int
      -> Int
      -> Int
      -> Int
      -> [Text]
      -> Text
      -> ISO8601
      -> AutoScalingGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( [Node]
x [Node] -> Text -> Either String (Maybe [Node])
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"SuspendedProcesses"
                      Either String (Maybe [Node]) -> [Node] -> Either String [Node]
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ [Node]
forall a. Monoid a => a
Prelude.mempty
                      Either String [Node]
-> ([Node] -> Either String (Maybe [SuspendedProcess]))
-> Either String (Maybe [SuspendedProcess])
forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b
Prelude.>>= ([Node] -> Either String [SuspendedProcess])
-> [Node] -> Either String (Maybe [SuspendedProcess])
forall (f :: * -> *) a b.
Applicative f =>
([a] -> f b) -> [a] -> f (Maybe b)
Core.may (Text -> [Node] -> Either String [SuspendedProcess]
forall a. FromXML a => Text -> [Node] -> Either String [a]
Core.parseXMLList Text
"member")
                  )
      Either
  String
  (Maybe [Text]
   -> Maybe [TagDescription]
   -> Text
   -> Int
   -> Int
   -> Int
   -> Int
   -> [Text]
   -> Text
   -> ISO8601
   -> AutoScalingGroup)
-> Either String (Maybe [Text])
-> Either
     String
     (Maybe [TagDescription]
      -> Text
      -> Int
      -> Int
      -> Int
      -> Int
      -> [Text]
      -> Text
      -> ISO8601
      -> AutoScalingGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( [Node]
x [Node] -> Text -> Either String (Maybe [Node])
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"LoadBalancerNames"
                      Either String (Maybe [Node]) -> [Node] -> Either String [Node]
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ [Node]
forall a. Monoid a => a
Prelude.mempty
                      Either String [Node]
-> ([Node] -> Either String (Maybe [Text]))
-> Either String (Maybe [Text])
forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b
Prelude.>>= ([Node] -> Either String [Text])
-> [Node] -> Either String (Maybe [Text])
forall (f :: * -> *) a b.
Applicative f =>
([a] -> f b) -> [a] -> f (Maybe b)
Core.may (Text -> [Node] -> Either String [Text]
forall a. FromXML a => Text -> [Node] -> Either String [a]
Core.parseXMLList Text
"member")
                  )
      Either
  String
  (Maybe [TagDescription]
   -> Text
   -> Int
   -> Int
   -> Int
   -> Int
   -> [Text]
   -> Text
   -> ISO8601
   -> AutoScalingGroup)
-> Either String (Maybe [TagDescription])
-> Either
     String
     (Text
      -> Int
      -> Int
      -> Int
      -> Int
      -> [Text]
      -> Text
      -> ISO8601
      -> AutoScalingGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( [Node]
x [Node] -> Text -> Either String (Maybe [Node])
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"Tags" Either String (Maybe [Node]) -> [Node] -> Either String [Node]
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ [Node]
forall a. Monoid a => a
Prelude.mempty
                      Either String [Node]
-> ([Node] -> Either String (Maybe [TagDescription]))
-> Either String (Maybe [TagDescription])
forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b
Prelude.>>= ([Node] -> Either String [TagDescription])
-> [Node] -> Either String (Maybe [TagDescription])
forall (f :: * -> *) a b.
Applicative f =>
([a] -> f b) -> [a] -> f (Maybe b)
Core.may (Text -> [Node] -> Either String [TagDescription]
forall a. FromXML a => Text -> [Node] -> Either String [a]
Core.parseXMLList Text
"member")
                  )
      Either
  String
  (Text
   -> Int
   -> Int
   -> Int
   -> Int
   -> [Text]
   -> Text
   -> ISO8601
   -> AutoScalingGroup)
-> Either String Text
-> Either
     String
     (Int
      -> Int
      -> Int
      -> Int
      -> [Text]
      -> Text
      -> ISO8601
      -> AutoScalingGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String Text
forall a. FromXML a => [Node] -> Text -> Either String a
Core..@ Text
"AutoScalingGroupName")
      Either
  String
  (Int
   -> Int
   -> Int
   -> Int
   -> [Text]
   -> Text
   -> ISO8601
   -> AutoScalingGroup)
-> Either String Int
-> Either
     String
     (Int
      -> Int -> Int -> [Text] -> Text -> ISO8601 -> AutoScalingGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String Int
forall a. FromXML a => [Node] -> Text -> Either String a
Core..@ Text
"MinSize")
      Either
  String
  (Int
   -> Int -> Int -> [Text] -> Text -> ISO8601 -> AutoScalingGroup)
-> Either String Int
-> Either
     String
     (Int -> Int -> [Text] -> Text -> ISO8601 -> AutoScalingGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String Int
forall a. FromXML a => [Node] -> Text -> Either String a
Core..@ Text
"MaxSize")
      Either
  String
  (Int -> Int -> [Text] -> Text -> ISO8601 -> AutoScalingGroup)
-> Either String Int
-> Either
     String (Int -> [Text] -> Text -> ISO8601 -> AutoScalingGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String Int
forall a. FromXML a => [Node] -> Text -> Either String a
Core..@ Text
"DesiredCapacity")
      Either
  String (Int -> [Text] -> Text -> ISO8601 -> AutoScalingGroup)
-> Either String Int
-> Either String ([Text] -> Text -> ISO8601 -> AutoScalingGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String Int
forall a. FromXML a => [Node] -> Text -> Either String a
Core..@ Text
"DefaultCooldown")
      Either String ([Text] -> Text -> ISO8601 -> AutoScalingGroup)
-> Either String [Text]
-> Either String (Text -> ISO8601 -> AutoScalingGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( [Node]
x [Node] -> Text -> Either String (Maybe [Node])
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"AvailabilityZones"
                      Either String (Maybe [Node]) -> [Node] -> Either String [Node]
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ [Node]
forall a. Monoid a => a
Prelude.mempty
                      Either String [Node]
-> ([Node] -> Either String [Text]) -> Either String [Text]
forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b
Prelude.>>= Text -> [Node] -> Either String [Text]
forall a. FromXML a => Text -> [Node] -> Either String [a]
Core.parseXMLList Text
"member"
                  )
      Either String (Text -> ISO8601 -> AutoScalingGroup)
-> Either String Text
-> Either String (ISO8601 -> AutoScalingGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String Text
forall a. FromXML a => [Node] -> Text -> Either String a
Core..@ Text
"HealthCheckType")
      Either String (ISO8601 -> AutoScalingGroup)
-> Either String ISO8601 -> Either String AutoScalingGroup
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String ISO8601
forall a. FromXML a => [Node] -> Text -> Either String a
Core..@ Text
"CreatedTime")

instance Prelude.Hashable AutoScalingGroup

instance Prelude.NFData AutoScalingGroup