@Generated(value="software.amazon.awssdk:codegen") public final class ScalingPolicy extends Object implements ToCopyableBuilder<ScalingPolicy.Builder,ScalingPolicy>
Describes a scaling policy.
Modifier and Type | Class and Description |
---|---|
static interface |
ScalingPolicy.Builder |
Modifier and Type | Method and Description |
---|---|
String |
adjustmentType()
The adjustment type, which specifies how
ScalingAdjustment is interpreted. |
List<Alarm> |
alarms()
The CloudWatch alarms related to the policy.
|
String |
autoScalingGroupName()
The name of the Auto Scaling group associated with this scaling policy.
|
static ScalingPolicy.Builder |
builder() |
Integer |
cooldown()
The amount of time, in seconds, after a scaling activity completes before any further dynamic scaling activities
can start.
|
boolean |
equals(Object obj) |
Integer |
estimatedInstanceWarmup()
The estimated time, in seconds, until a newly launched instance can contribute to the CloudWatch metrics.
|
<T> Optional<T> |
getValueForField(String fieldName,
Class<T> clazz) |
int |
hashCode() |
String |
metricAggregationType()
The aggregation type for the CloudWatch metrics.
|
Integer |
minAdjustmentMagnitude()
The minimum number of instances to scale.
|
Integer |
minAdjustmentStep()
Available for backward compatibility.
|
String |
policyARN()
The Amazon Resource Name (ARN) of the policy.
|
String |
policyName()
The name of the scaling policy.
|
String |
policyType()
The policy type.
|
Integer |
scalingAdjustment()
The amount by which to scale, based on the specified adjustment type.
|
static Class<? extends ScalingPolicy.Builder> |
serializableBuilderClass() |
List<StepAdjustment> |
stepAdjustments()
A set of adjustments that enable you to scale based on the size of the alarm breach.
|
TargetTrackingConfiguration |
targetTrackingConfiguration()
A target tracking policy.
|
ScalingPolicy.Builder |
toBuilder()
Take this object and create a builder that contains all of the current property values of this object.
|
String |
toString() |
copy
public String autoScalingGroupName()
The name of the Auto Scaling group associated with this scaling policy.
public String policyName()
The name of the scaling policy.
public String policyARN()
The Amazon Resource Name (ARN) of the policy.
public String policyType()
The policy type. Valid values are SimpleScaling
and StepScaling
.
SimpleScaling
and StepScaling
.public String adjustmentType()
The adjustment type, which specifies how ScalingAdjustment
is interpreted. Valid values are
ChangeInCapacity
, ExactCapacity
, and PercentChangeInCapacity
.
ScalingAdjustment
is interpreted. Valid values are
ChangeInCapacity
, ExactCapacity
, and PercentChangeInCapacity
.public Integer minAdjustmentStep()
Available for backward compatibility. Use MinAdjustmentMagnitude
instead.
MinAdjustmentMagnitude
instead.public Integer minAdjustmentMagnitude()
The minimum number of instances to scale. If the value of AdjustmentType
is
PercentChangeInCapacity
, the scaling policy changes the DesiredCapacity
of the Auto
Scaling group by at least this many instances. Otherwise, the error is ValidationError
.
AdjustmentType
is
PercentChangeInCapacity
, the scaling policy changes the DesiredCapacity
of the
Auto Scaling group by at least this many instances. Otherwise, the error is ValidationError
.public Integer scalingAdjustment()
The amount by which to scale, based on the specified adjustment type. A positive value adds to the current capacity while a negative number removes from the current capacity.
public Integer cooldown()
The amount of time, in seconds, after a scaling activity completes before any further dynamic scaling activities can start.
public List<StepAdjustment> stepAdjustments()
A set of adjustments that enable you to scale based on the size of the alarm breach.
Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.
public String metricAggregationType()
The aggregation type for the CloudWatch metrics. Valid values are Minimum
, Maximum
, and
Average
.
Minimum
,
Maximum
, and Average
.public Integer estimatedInstanceWarmup()
The estimated time, in seconds, until a newly launched instance can contribute to the CloudWatch metrics.
public List<Alarm> alarms()
The CloudWatch alarms related to the policy.
Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.
public TargetTrackingConfiguration targetTrackingConfiguration()
A target tracking policy.
public ScalingPolicy.Builder toBuilder()
ToCopyableBuilder
toBuilder
in interface ToCopyableBuilder<ScalingPolicy.Builder,ScalingPolicy>
public static ScalingPolicy.Builder builder()
public static Class<? extends ScalingPolicy.Builder> serializableBuilderClass()
Copyright © 2017 Amazon Web Services, Inc. All Rights Reserved.