Interface BasicTargetTrackingScalingPolicyProps

All Superinterfaces:
BaseTargetTrackingProps, software.amazon.jsii.JsiiSerializable
All Known Subinterfaces:
TargetTrackingScalingPolicyProps
All Known Implementing Classes:
BasicTargetTrackingScalingPolicyProps.Jsii$Proxy, TargetTrackingScalingPolicyProps.Jsii$Proxy

@Generated(value="jsii-pacmak/1.84.0 (build 5404dcf)", date="2023-06-19T16:30:45.194Z") @Stability(Stable) public interface BasicTargetTrackingScalingPolicyProps extends software.amazon.jsii.JsiiSerializable, BaseTargetTrackingProps
Properties for a Target Tracking policy that include the metric but exclude the target.

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.autoscaling.*;
 import software.amazon.awscdk.services.cloudwatch.*;
 import software.amazon.awscdk.core.*;
 Metric metric;
 BasicTargetTrackingScalingPolicyProps basicTargetTrackingScalingPolicyProps = BasicTargetTrackingScalingPolicyProps.builder()
         .targetValue(123)
         // the properties below are optional
         .cooldown(Duration.minutes(30))
         .customMetric(metric)
         .disableScaleIn(false)
         .estimatedInstanceWarmup(Duration.minutes(30))
         .predefinedMetric(PredefinedMetric.ASG_AVERAGE_CPU_UTILIZATION)
         .resourceLabel("resourceLabel")
         .build();
 
  • Method Details

    • getTargetValue

      @Stability(Stable) @NotNull Number getTargetValue()
      The target value for the metric.
    • getCustomMetric

      @Stability(Stable) @Nullable default IMetric getCustomMetric()
      A custom metric for application autoscaling.

      The metric must track utilization. Scaling out will happen if the metric is higher than the target value, scaling in will happen in the metric is lower than the target value.

      Exactly one of customMetric or predefinedMetric must be specified.

      Default: - No custom metric.

    • getPredefinedMetric

      @Stability(Stable) @Nullable default PredefinedMetric getPredefinedMetric()
      A predefined metric for application autoscaling.

      The metric must track utilization. Scaling out will happen if the metric is higher than the target value, scaling in will happen in the metric is lower than the target value.

      Exactly one of customMetric or predefinedMetric must be specified.

      Default: - No predefined metric.

    • getResourceLabel

      @Stability(Stable) @Nullable default String getResourceLabel()
      The resource label associated with the predefined metric.

      Should be supplied if the predefined metric is ALBRequestCountPerTarget, and the format should be:

      app/invalid input: '<'load-balancer-name>/invalid input: '<'load-balancer-id>/targetgroup/invalid input: '<'target-group-name>/invalid input: '<'target-group-id>

      Default: - No resource label.

    • builder

      @Stability(Stable) static BasicTargetTrackingScalingPolicyProps.Builder builder()
      Returns:
      a BasicTargetTrackingScalingPolicyProps.Builder of BasicTargetTrackingScalingPolicyProps