Show / Hide Table of Contents

Class CfnScalingPolicy.TargetTrackingConfigurationProperty

TargetTrackingConfiguration is a property of the AWS::AutoScaling::ScalingPolicy resource that specifies a target tracking scaling policy configuration for Amazon EC2 Auto Scaling.

Inheritance
object
CfnScalingPolicy.TargetTrackingConfigurationProperty
Implements
CfnScalingPolicy.ITargetTrackingConfigurationProperty
Inherited Members
object.GetType()
object.MemberwiseClone()
object.ToString()
object.Equals(object)
object.Equals(object, object)
object.ReferenceEquals(object, object)
object.GetHashCode()
Namespace: Amazon.CDK.AWS.AutoScaling
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public class CfnScalingPolicy.TargetTrackingConfigurationProperty : CfnScalingPolicy.ITargetTrackingConfigurationProperty
Syntax (vb)
Public Class CfnScalingPolicy.TargetTrackingConfigurationProperty Implements CfnScalingPolicy.ITargetTrackingConfigurationProperty
Remarks

For more information about scaling policies, see Dynamic scaling in the Amazon EC2 Auto Scaling User Guide .

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-autoscaling-scalingpolicy-targettrackingconfiguration.html

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.AWS.AutoScaling;

             var targetTrackingConfigurationProperty = new TargetTrackingConfigurationProperty {
                 TargetValue = 123,

                 // the properties below are optional
                 CustomizedMetricSpecification = new CustomizedMetricSpecificationProperty {
                     Dimensions = new [] { new MetricDimensionProperty {
                         Name = "name",
                         Value = "value"
                     } },
                     MetricName = "metricName",
                     Metrics = new [] { new TargetTrackingMetricDataQueryProperty {
                         Id = "id",

                         // the properties below are optional
                         Expression = "expression",
                         Label = "label",
                         MetricStat = new TargetTrackingMetricStatProperty {
                             Metric = new MetricProperty {
                                 MetricName = "metricName",
                                 Namespace = "namespace",

                                 // the properties below are optional
                                 Dimensions = new [] { new MetricDimensionProperty {
                                     Name = "name",
                                     Value = "value"
                                 } }
                             },
                             Stat = "stat",

                             // the properties below are optional
                             Period = 123,
                             Unit = "unit"
                         },
                         Period = 123,
                         ReturnData = false
                     } },
                     Namespace = "namespace",
                     Period = 123,
                     Statistic = "statistic",
                     Unit = "unit"
                 },
                 DisableScaleIn = false,
                 PredefinedMetricSpecification = new PredefinedMetricSpecificationProperty {
                     PredefinedMetricType = "predefinedMetricType",

                     // the properties below are optional
                     ResourceLabel = "resourceLabel"
                 }
             };

Synopsis

Constructors

TargetTrackingConfigurationProperty()

TargetTrackingConfiguration is a property of the AWS::AutoScaling::ScalingPolicy resource that specifies a target tracking scaling policy configuration for Amazon EC2 Auto Scaling.

Properties

CustomizedMetricSpecification

A customized metric.

DisableScaleIn

Indicates whether scaling in by the target tracking scaling policy is disabled.

PredefinedMetricSpecification

A predefined metric.

TargetValue

The target value for the metric.

Constructors

TargetTrackingConfigurationProperty()

TargetTrackingConfiguration is a property of the AWS::AutoScaling::ScalingPolicy resource that specifies a target tracking scaling policy configuration for Amazon EC2 Auto Scaling.

public TargetTrackingConfigurationProperty()
Remarks

For more information about scaling policies, see Dynamic scaling in the Amazon EC2 Auto Scaling User Guide .

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-autoscaling-scalingpolicy-targettrackingconfiguration.html

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.AWS.AutoScaling;

             var targetTrackingConfigurationProperty = new TargetTrackingConfigurationProperty {
                 TargetValue = 123,

                 // the properties below are optional
                 CustomizedMetricSpecification = new CustomizedMetricSpecificationProperty {
                     Dimensions = new [] { new MetricDimensionProperty {
                         Name = "name",
                         Value = "value"
                     } },
                     MetricName = "metricName",
                     Metrics = new [] { new TargetTrackingMetricDataQueryProperty {
                         Id = "id",

                         // the properties below are optional
                         Expression = "expression",
                         Label = "label",
                         MetricStat = new TargetTrackingMetricStatProperty {
                             Metric = new MetricProperty {
                                 MetricName = "metricName",
                                 Namespace = "namespace",

                                 // the properties below are optional
                                 Dimensions = new [] { new MetricDimensionProperty {
                                     Name = "name",
                                     Value = "value"
                                 } }
                             },
                             Stat = "stat",

                             // the properties below are optional
                             Period = 123,
                             Unit = "unit"
                         },
                         Period = 123,
                         ReturnData = false
                     } },
                     Namespace = "namespace",
                     Period = 123,
                     Statistic = "statistic",
                     Unit = "unit"
                 },
                 DisableScaleIn = false,
                 PredefinedMetricSpecification = new PredefinedMetricSpecificationProperty {
                     PredefinedMetricType = "predefinedMetricType",

                     // the properties below are optional
                     ResourceLabel = "resourceLabel"
                 }
             };

Properties

CustomizedMetricSpecification

A customized metric.

public object? CustomizedMetricSpecification { get; set; }
Property Value

object

Remarks

You must specify either a predefined metric or a customized metric.

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-autoscaling-scalingpolicy-targettrackingconfiguration.html#cfn-autoscaling-scalingpolicy-targettrackingconfiguration-customizedmetricspecification

DisableScaleIn

Indicates whether scaling in by the target tracking scaling policy is disabled.

public object? DisableScaleIn { get; set; }
Property Value

object

Remarks

If scaling in is disabled, the target tracking scaling policy doesn't remove instances from the Auto Scaling group. Otherwise, the target tracking scaling policy can remove instances from the Auto Scaling group. The default is false .

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-autoscaling-scalingpolicy-targettrackingconfiguration.html#cfn-autoscaling-scalingpolicy-targettrackingconfiguration-disablescalein

PredefinedMetricSpecification

A predefined metric.

public object? PredefinedMetricSpecification { get; set; }
Property Value

object

Remarks

You must specify either a predefined metric or a customized metric.

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-autoscaling-scalingpolicy-targettrackingconfiguration.html#cfn-autoscaling-scalingpolicy-targettrackingconfiguration-predefinedmetricspecification

TargetValue

The target value for the metric.

public double TargetValue { get; set; }
Property Value

double

Remarks
Some metrics are based on a count instead of a percentage, such as the request count for an Application Load Balancer or the number of messages in an SQS queue. If the scaling policy specifies one of these metrics, specify the target utilization as the optimal average request or message count per instance during any one-minute interval.

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-autoscaling-scalingpolicy-targettrackingconfiguration.html#cfn-autoscaling-scalingpolicy-targettrackingconfiguration-targetvalue

Implements

CfnScalingPolicy.ITargetTrackingConfigurationProperty
Back to top Generated by DocFX