Class StepScalingActionProps.Builder
java.lang.Object
software.amazon.awscdk.services.applicationautoscaling.StepScalingActionProps.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<StepScalingActionProps>
- Enclosing interface:
- StepScalingActionProps
@Stability(Stable)
public static final class StepScalingActionProps.Builder
extends Object
implements software.amazon.jsii.Builder<StepScalingActionProps>
A builder for
StepScalingActionProps
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionadjustmentType
(AdjustmentType adjustmentType) Sets the value ofStepScalingActionProps.getAdjustmentType()
build()
Builds the configured instance.Sets the value ofStepScalingActionProps.getCooldown()
metricAggregationType
(MetricAggregationType metricAggregationType) Sets the value ofStepScalingActionProps.getMetricAggregationType()
minAdjustmentMagnitude
(Number minAdjustmentMagnitude) Sets the value ofStepScalingActionProps.getMinAdjustmentMagnitude()
policyName
(String policyName) Sets the value ofStepScalingActionProps.getPolicyName()
scalingTarget
(IScalableTarget scalingTarget) Sets the value ofStepScalingActionProps.getScalingTarget()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
scalingTarget
@Stability(Stable) public StepScalingActionProps.Builder scalingTarget(IScalableTarget scalingTarget) Sets the value ofStepScalingActionProps.getScalingTarget()
- Parameters:
scalingTarget
- The scalable target. This parameter is required.- Returns:
this
-
adjustmentType
@Stability(Stable) public StepScalingActionProps.Builder adjustmentType(AdjustmentType adjustmentType) Sets the value ofStepScalingActionProps.getAdjustmentType()
- Parameters:
adjustmentType
- How the adjustment numbers are interpreted.- Returns:
this
-
cooldown
Sets the value ofStepScalingActionProps.getCooldown()
- Parameters:
cooldown
- Grace period after scaling activity. For scale out policies, multiple scale outs during the cooldown period are squashed so that only the biggest scale out happens.For scale in policies, subsequent scale ins during the cooldown period are ignored.
- Returns:
this
-
metricAggregationType
@Stability(Stable) public StepScalingActionProps.Builder metricAggregationType(MetricAggregationType metricAggregationType) Sets the value ofStepScalingActionProps.getMetricAggregationType()
- Parameters:
metricAggregationType
- The aggregation type for the CloudWatch metrics.- Returns:
this
-
minAdjustmentMagnitude
@Stability(Stable) public StepScalingActionProps.Builder minAdjustmentMagnitude(Number minAdjustmentMagnitude) Sets the value ofStepScalingActionProps.getMinAdjustmentMagnitude()
- Parameters:
minAdjustmentMagnitude
- Minimum absolute number to adjust capacity with as result of percentage scaling. Only when using AdjustmentType = PercentChangeInCapacity, this number controls the minimum absolute effect size.- Returns:
this
-
policyName
Sets the value ofStepScalingActionProps.getPolicyName()
- Parameters:
policyName
- A name for the scaling policy.- Returns:
this
-
build
Builds the configured instance.- Specified by:
build
in interfacesoftware.amazon.jsii.Builder<StepScalingActionProps>
- Returns:
- a new instance of
StepScalingActionProps
- Throws:
NullPointerException
- if any required attribute was not provided
-