libZSservicesZSamazonka-autoscalingZSamazonka-autoscaling
Copyright(c) 2013-2021 Brendan Hay
LicenseMozilla Public License, v. 2.0.
MaintainerBrendan Hay <brendan.g.hay+amazonka@gmail.com>
Stabilityauto-generated
Portabilitynon-portable (GHC extensions)
Safe HaskellNone

Amazonka.AutoScaling.TerminateInstanceInAutoScalingGroup

Description

Terminates the specified instance and optionally adjusts the desired group size. This operation cannot be called on instances in a warm pool.

This call simply makes a termination request. The instance is not terminated immediately. When an instance is terminated, the instance status changes to terminated. You can't connect to or start an instance after you've terminated it.

If you do not specify the option to decrement the desired capacity, Amazon EC2 Auto Scaling launches instances to replace the ones that are terminated.

By default, Amazon EC2 Auto Scaling balances instances across all Availability Zones. If you decrement the desired capacity, your Auto Scaling group can become unbalanced between Availability Zones. Amazon EC2 Auto Scaling tries to rebalance the group, and rebalancing might terminate instances in other zones. For more information, see Rebalancing activities in the Amazon EC2 Auto Scaling User Guide.

Synopsis

Creating a Request

data TerminateInstanceInAutoScalingGroup Source #

Constructors

TerminateInstanceInAutoScalingGroup' 

Fields

Instances

Instances details
Eq TerminateInstanceInAutoScalingGroup Source # 
Instance details

Defined in Amazonka.AutoScaling.TerminateInstanceInAutoScalingGroup

Read TerminateInstanceInAutoScalingGroup Source # 
Instance details

Defined in Amazonka.AutoScaling.TerminateInstanceInAutoScalingGroup

Show TerminateInstanceInAutoScalingGroup Source # 
Instance details

Defined in Amazonka.AutoScaling.TerminateInstanceInAutoScalingGroup

Generic TerminateInstanceInAutoScalingGroup Source # 
Instance details

Defined in Amazonka.AutoScaling.TerminateInstanceInAutoScalingGroup

NFData TerminateInstanceInAutoScalingGroup Source # 
Instance details

Defined in Amazonka.AutoScaling.TerminateInstanceInAutoScalingGroup

Hashable TerminateInstanceInAutoScalingGroup Source # 
Instance details

Defined in Amazonka.AutoScaling.TerminateInstanceInAutoScalingGroup

AWSRequest TerminateInstanceInAutoScalingGroup Source # 
Instance details

Defined in Amazonka.AutoScaling.TerminateInstanceInAutoScalingGroup

ToHeaders TerminateInstanceInAutoScalingGroup Source # 
Instance details

Defined in Amazonka.AutoScaling.TerminateInstanceInAutoScalingGroup

ToPath TerminateInstanceInAutoScalingGroup Source # 
Instance details

Defined in Amazonka.AutoScaling.TerminateInstanceInAutoScalingGroup

ToQuery TerminateInstanceInAutoScalingGroup Source # 
Instance details

Defined in Amazonka.AutoScaling.TerminateInstanceInAutoScalingGroup

type Rep TerminateInstanceInAutoScalingGroup Source # 
Instance details

Defined in Amazonka.AutoScaling.TerminateInstanceInAutoScalingGroup

type Rep TerminateInstanceInAutoScalingGroup = D1 ('MetaData "TerminateInstanceInAutoScalingGroup" "Amazonka.AutoScaling.TerminateInstanceInAutoScalingGroup" "libZSservicesZSamazonka-autoscalingZSamazonka-autoscaling" 'False) (C1 ('MetaCons "TerminateInstanceInAutoScalingGroup'" 'PrefixI 'True) (S1 ('MetaSel ('Just "instanceId") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Text) :*: S1 ('MetaSel ('Just "shouldDecrementDesiredCapacity") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Bool)))
type AWSResponse TerminateInstanceInAutoScalingGroup Source # 
Instance details

Defined in Amazonka.AutoScaling.TerminateInstanceInAutoScalingGroup

newTerminateInstanceInAutoScalingGroup Source #

Create a value of TerminateInstanceInAutoScalingGroup with all optional fields omitted.

Use generic-lens or optics to modify other optional fields.

The following record fields are available, with the corresponding lenses provided for backwards compatibility:

$sel:instanceId:TerminateInstanceInAutoScalingGroup', terminateInstanceInAutoScalingGroup_instanceId - The ID of the instance.

$sel:shouldDecrementDesiredCapacity:TerminateInstanceInAutoScalingGroup', terminateInstanceInAutoScalingGroup_shouldDecrementDesiredCapacity - Indicates whether terminating the instance also decrements the size of the Auto Scaling group.

Request Lenses

terminateInstanceInAutoScalingGroup_shouldDecrementDesiredCapacity :: Lens' TerminateInstanceInAutoScalingGroup Bool Source #

Indicates whether terminating the instance also decrements the size of the Auto Scaling group.

Destructuring the Response

data TerminateInstanceInAutoScalingGroupResponse Source #

Constructors

TerminateInstanceInAutoScalingGroupResponse' 

Fields

Instances

Instances details
Eq TerminateInstanceInAutoScalingGroupResponse Source # 
Instance details

Defined in Amazonka.AutoScaling.TerminateInstanceInAutoScalingGroup

Read TerminateInstanceInAutoScalingGroupResponse Source # 
Instance details

Defined in Amazonka.AutoScaling.TerminateInstanceInAutoScalingGroup

Show TerminateInstanceInAutoScalingGroupResponse Source # 
Instance details

Defined in Amazonka.AutoScaling.TerminateInstanceInAutoScalingGroup

Generic TerminateInstanceInAutoScalingGroupResponse Source # 
Instance details

Defined in Amazonka.AutoScaling.TerminateInstanceInAutoScalingGroup

NFData TerminateInstanceInAutoScalingGroupResponse Source # 
Instance details

Defined in Amazonka.AutoScaling.TerminateInstanceInAutoScalingGroup

type Rep TerminateInstanceInAutoScalingGroupResponse Source # 
Instance details

Defined in Amazonka.AutoScaling.TerminateInstanceInAutoScalingGroup

type Rep TerminateInstanceInAutoScalingGroupResponse = D1 ('MetaData "TerminateInstanceInAutoScalingGroupResponse" "Amazonka.AutoScaling.TerminateInstanceInAutoScalingGroup" "libZSservicesZSamazonka-autoscalingZSamazonka-autoscaling" 'False) (C1 ('MetaCons "TerminateInstanceInAutoScalingGroupResponse'" 'PrefixI 'True) (S1 ('MetaSel ('Just "activity") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Activity)) :*: S1 ('MetaSel ('Just "httpStatus") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Int)))

Response Lenses