Class StepScalingAction.Builder

java.lang.Object
software.amazon.awscdk.services.applicationautoscaling.StepScalingAction.Builder
All Implemented Interfaces:
software.amazon.jsii.Builder<StepScalingAction>
Enclosing class:
StepScalingAction

@Stability(Stable) public static final class StepScalingAction.Builder extends Object implements software.amazon.jsii.Builder<StepScalingAction>
A fluent builder for StepScalingAction.
  • Method Details

    • create

      @Stability(Stable) public static StepScalingAction.Builder create(software.constructs.Construct scope, String id)
      Parameters:
      scope - This parameter is required.
      id - This parameter is required.
      Returns:
      a new instance of StepScalingAction.Builder.
    • scalingTarget

      @Stability(Stable) public StepScalingAction.Builder scalingTarget(IScalableTarget scalingTarget)
      The scalable target.

      Parameters:
      scalingTarget - The scalable target. This parameter is required.
      Returns:
      this
    • adjustmentType

      @Stability(Stable) public StepScalingAction.Builder adjustmentType(AdjustmentType adjustmentType)
      How the adjustment numbers are interpreted.

      Default: ChangeInCapacity

      Parameters:
      adjustmentType - How the adjustment numbers are interpreted. This parameter is required.
      Returns:
      this
    • cooldown

      @Stability(Stable) public StepScalingAction.Builder cooldown(Duration 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.

      Default: No cooldown period

      Parameters:
      cooldown - Grace period after scaling activity. This parameter is required.
      Returns:
      this
      See Also:
    • metricAggregationType

      @Stability(Stable) public StepScalingAction.Builder metricAggregationType(MetricAggregationType metricAggregationType)
      The aggregation type for the CloudWatch metrics.

      Default: Average

      Parameters:
      metricAggregationType - The aggregation type for the CloudWatch metrics. This parameter is required.
      Returns:
      this
    • minAdjustmentMagnitude

      @Stability(Stable) public StepScalingAction.Builder minAdjustmentMagnitude(Number 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.

      Default: No minimum scaling effect

      Parameters:
      minAdjustmentMagnitude - Minimum absolute number to adjust capacity with as result of percentage scaling. This parameter is required.
      Returns:
      this
    • policyName

      @Stability(Stable) public StepScalingAction.Builder policyName(String policyName)
      A name for the scaling policy.

      Default: Automatically generated name

      Parameters:
      policyName - A name for the scaling policy. This parameter is required.
      Returns:
      this
    • build

      @Stability(Stable) public StepScalingAction build()
      Specified by:
      build in interface software.amazon.jsii.Builder<StepScalingAction>
      Returns:
      a newly built instance of StepScalingAction.