@Stability(value=Stable)
public static interface CfnScalingPolicy.StepAdjustmentProperty
extends software.amazon.jsii.JsiiSerializable
For the following examples, suppose that you have an alarm with a breach threshold of 50:
For more information, see Step adjustments in the Application Auto Scaling User Guide .
You can find a sample template snippet in the Examples section of the AWS::ApplicationAutoScaling::ScalingPolicy documentation.
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.*;
StepAdjustmentProperty stepAdjustmentProperty = StepAdjustmentProperty.builder()
.scalingAdjustment(123)
// the properties below are optional
.metricIntervalLowerBound(123)
.metricIntervalUpperBound(123)
.build();
| Modifier and Type | Interface and Description |
|---|---|
static class |
CfnScalingPolicy.StepAdjustmentProperty.Builder
A builder for
CfnScalingPolicy.StepAdjustmentProperty |
static class |
CfnScalingPolicy.StepAdjustmentProperty.Jsii$Proxy
An implementation for
CfnScalingPolicy.StepAdjustmentProperty |
| Modifier and Type | Method and Description |
|---|---|
static CfnScalingPolicy.StepAdjustmentProperty.Builder |
builder() |
default Number |
getMetricIntervalLowerBound()
The lower bound for the difference between the alarm threshold and the CloudWatch metric.
|
default Number |
getMetricIntervalUpperBound()
The upper bound for the difference between the alarm threshold and the CloudWatch metric.
|
Number |
getScalingAdjustment()
The amount by which to scale.
|
@Stability(value=Stable) @NotNull Number getScalingAdjustment()
The adjustment is based on the value that you specified in the AdjustmentType property (either an absolute number or a percentage). A positive value adds to the current capacity and a negative number subtracts from the current capacity.
@Stability(value=Stable) @Nullable default Number getMetricIntervalLowerBound()
If the metric value is above the breach threshold, the lower bound is inclusive (the metric must be greater than or equal to the threshold plus the lower bound). Otherwise, it is exclusive (the metric must be greater than the threshold plus the lower bound). A null value indicates negative infinity.
You must specify at least one upper or lower bound.
@Stability(value=Stable) @Nullable default Number getMetricIntervalUpperBound()
If the metric value is above the breach threshold, the upper bound is exclusive (the metric must be less than the threshold plus the upper bound). Otherwise, it is inclusive (the metric must be less than or equal to the threshold plus the upper bound). A null value indicates positive infinity.
You must specify at least one upper or lower bound.
@Stability(value=Stable) static CfnScalingPolicy.StepAdjustmentProperty.Builder builder()
Copyright © 2022. All rights reserved.