Interface CfnScalingPolicy.TargetTrackingScalingPolicyConfigurationProperty
- All Superinterfaces:
software.amazon.jsii.JsiiSerializable
- All Known Implementing Classes:
CfnScalingPolicy.TargetTrackingScalingPolicyConfigurationProperty.Jsii$Proxy
- Enclosing class:
CfnScalingPolicy
TargetTrackingScalingPolicyConfiguration
is a property of the AWS::ApplicationAutoScaling::ScalingPolicy resource that specifies a target tracking scaling policy configuration for Application Auto Scaling. Use a target tracking scaling policy to adjust the capacity of the specified scalable target in response to actual workloads, so that resource utilization remains at or near the target utilization value.
For more information, see Target tracking scaling policies in the Application Auto Scaling User Guide .
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import software.amazon.awscdk.services.applicationautoscaling.*; TargetTrackingScalingPolicyConfigurationProperty targetTrackingScalingPolicyConfigurationProperty = TargetTrackingScalingPolicyConfigurationProperty.builder() .targetValue(123) // the properties below are optional .customizedMetricSpecification(CustomizedMetricSpecificationProperty.builder() .dimensions(List.of(MetricDimensionProperty.builder() .name("name") .value("value") .build())) .metricName("metricName") .metrics(List.of(TargetTrackingMetricDataQueryProperty.builder() .expression("expression") .id("id") .label("label") .metricStat(TargetTrackingMetricStatProperty.builder() .metric(TargetTrackingMetricProperty.builder() .dimensions(List.of(TargetTrackingMetricDimensionProperty.builder() .name("name") .value("value") .build())) .metricName("metricName") .namespace("namespace") .build()) .stat("stat") .unit("unit") .build()) .returnData(false) .build())) .namespace("namespace") .statistic("statistic") .unit("unit") .build()) .disableScaleIn(false) .predefinedMetricSpecification(PredefinedMetricSpecificationProperty.builder() .predefinedMetricType("predefinedMetricType") // the properties below are optional .resourceLabel("resourceLabel") .build()) .scaleInCooldown(123) .scaleOutCooldown(123) .build();
- See Also:
-
Nested Class Summary
Modifier and TypeInterfaceDescriptionstatic final class
static final class
An implementation forCfnScalingPolicy.TargetTrackingScalingPolicyConfigurationProperty
-
Method Summary
Modifier and TypeMethodDescriptionbuilder()
default Object
A customized metric.default Object
Indicates whether scale in by the target tracking scaling policy is disabled.default Object
A predefined metric.default Number
The amount of time, in seconds, after a scale-in activity completes before another scale-in activity can start.default Number
The amount of time, in seconds, to wait for a previous scale-out activity to take effect.The target value for the metric.Methods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Method Details
-
getTargetValue
The target value for the metric.Although this property accepts numbers of type Double, it won't accept values that are either too small or too large. Values must be in the range of -2^360 to 2^360. The value must be a valid number based on the choice of metric. For example, if the metric is CPU utilization, then the target value is a percent value that represents how much of the CPU can be used before scaling out.
- See Also:
-
getCustomizedMetricSpecification
A customized metric.You can specify either a predefined metric or a customized metric.
- See Also:
-
getDisableScaleIn
Indicates whether scale in by the target tracking scaling policy is disabled.If the value is
true
, scale in is disabled and the target tracking scaling policy won't remove capacity from the scalable target. Otherwise, scale in is enabled and the target tracking scaling policy can remove capacity from the scalable target. The default value isfalse
.- See Also:
-
getPredefinedMetricSpecification
A predefined metric.You can specify either a predefined metric or a customized metric.
- See Also:
-
getScaleInCooldown
The amount of time, in seconds, after a scale-in activity completes before another scale-in activity can start.For more information and for default values, see Define cooldown periods in the Application Auto Scaling User Guide .
- See Also:
-
getScaleOutCooldown
The amount of time, in seconds, to wait for a previous scale-out activity to take effect.For more information and for default values, see Define cooldown periods in the Application Auto Scaling User Guide .
- See Also:
-
builder
@Stability(Stable) static CfnScalingPolicy.TargetTrackingScalingPolicyConfigurationProperty.Builder builder()
-