Class CfnAutoScalingGroupPropsMixin.InstanceLifecyclePolicyProperty
The instance lifecycle policy for the Auto Scaling group.
Inherited Members
Namespace: Amazon.CDK.CfnPropertyMixins.AWS.AutoScaling
Assembly: Amazon.CDK.CfnPropertyMixins.dll
Syntax (csharp)
public class CfnAutoScalingGroupPropsMixin.InstanceLifecyclePolicyProperty : CfnAutoScalingGroupPropsMixin.IInstanceLifecyclePolicyProperty
Syntax (vb)
Public Class CfnAutoScalingGroupPropsMixin.InstanceLifecyclePolicyProperty Implements CfnAutoScalingGroupPropsMixin.IInstanceLifecyclePolicyProperty
Remarks
This policy controls instance behavior when an instance transitions through its lifecycle states. Configure retention triggers to specify when instances should move to a Retained state instead of automatic termination.
For more information, see Control instance retention with instance lifecycle policies in the Amazon EC2 Auto Scaling User Guide .
ExampleMetadata: fixture=_generated
Examples
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.CfnPropertyMixins.AWS.AutoScaling;
var instanceLifecyclePolicyProperty = new InstanceLifecyclePolicyProperty {
RetentionTriggers = new RetentionTriggersProperty {
TerminateHookAbandon = "terminateHookAbandon"
}
};
Synopsis
Constructors
| InstanceLifecyclePolicyProperty() | The instance lifecycle policy for the Auto Scaling group. |
Properties
| RetentionTriggers | Specifies the conditions that trigger instance retention behavior. |
Constructors
InstanceLifecyclePolicyProperty()
The instance lifecycle policy for the Auto Scaling group.
public InstanceLifecyclePolicyProperty()
Remarks
This policy controls instance behavior when an instance transitions through its lifecycle states. Configure retention triggers to specify when instances should move to a Retained state instead of automatic termination.
For more information, see Control instance retention with instance lifecycle policies in the Amazon EC2 Auto Scaling User Guide .
ExampleMetadata: fixture=_generated
Examples
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.CfnPropertyMixins.AWS.AutoScaling;
var instanceLifecyclePolicyProperty = new InstanceLifecyclePolicyProperty {
RetentionTriggers = new RetentionTriggersProperty {
TerminateHookAbandon = "terminateHookAbandon"
}
};
Properties
RetentionTriggers
Specifies the conditions that trigger instance retention behavior.
public object? RetentionTriggers { get; set; }
Property Value
Remarks
These triggers determine when instances should move to a Retained state instead of automatic termination. This allows you to maintain control over instance management when lifecycles transition and operations fail.
Type union: either IResolvable or CfnAutoScalingGroupPropsMixin.IRetentionTriggersProperty