@Generated(value="com.amazonaws:aws-java-sdk-code-generator") public class PutScalingPolicyRequest extends AmazonWebServiceRequest implements Serializable, Cloneable
NOOP
Constructor and Description |
---|
PutScalingPolicyRequest() |
Modifier and Type | Method and Description |
---|---|
PutScalingPolicyRequest |
clone()
Creates a shallow clone of this object for all fields except the handler context.
|
boolean |
equals(Object obj) |
String |
getAdjustmentType()
Specifies how the scaling adjustment is interpreted (for example, an absolute number or a percentage).
|
String |
getAutoScalingGroupName()
The name of the Auto Scaling group.
|
Integer |
getCooldown()
The duration of the policy's cooldown period, in seconds.
|
Boolean |
getEnabled()
Indicates whether the scaling policy is enabled or disabled.
|
Integer |
getEstimatedInstanceWarmup()
The estimated time, in seconds, until a newly launched instance can contribute to the CloudWatch metrics.
|
String |
getMetricAggregationType()
The aggregation type for the CloudWatch metrics.
|
Integer |
getMinAdjustmentMagnitude()
The minimum value to scale by when the adjustment type is
PercentChangeInCapacity . |
Integer |
getMinAdjustmentStep()
Available for backward compatibility.
|
String |
getPolicyName()
The name of the policy.
|
String |
getPolicyType()
One of the following policy types:
|
Integer |
getScalingAdjustment()
The amount by which to scale, based on the specified adjustment type.
|
List<StepAdjustment> |
getStepAdjustments()
A set of adjustments that enable you to scale based on the size of the alarm breach.
|
TargetTrackingConfiguration |
getTargetTrackingConfiguration()
A target tracking scaling policy.
|
int |
hashCode() |
Boolean |
isEnabled()
Indicates whether the scaling policy is enabled or disabled.
|
void |
setAdjustmentType(String adjustmentType)
Specifies how the scaling adjustment is interpreted (for example, an absolute number or a percentage).
|
void |
setAutoScalingGroupName(String autoScalingGroupName)
The name of the Auto Scaling group.
|
void |
setCooldown(Integer cooldown)
The duration of the policy's cooldown period, in seconds.
|
void |
setEnabled(Boolean enabled)
Indicates whether the scaling policy is enabled or disabled.
|
void |
setEstimatedInstanceWarmup(Integer estimatedInstanceWarmup)
The estimated time, in seconds, until a newly launched instance can contribute to the CloudWatch metrics.
|
void |
setMetricAggregationType(String metricAggregationType)
The aggregation type for the CloudWatch metrics.
|
void |
setMinAdjustmentMagnitude(Integer minAdjustmentMagnitude)
The minimum value to scale by when the adjustment type is
PercentChangeInCapacity . |
void |
setMinAdjustmentStep(Integer minAdjustmentStep)
Available for backward compatibility.
|
void |
setPolicyName(String policyName)
The name of the policy.
|
void |
setPolicyType(String policyType)
One of the following policy types:
|
void |
setScalingAdjustment(Integer scalingAdjustment)
The amount by which to scale, based on the specified adjustment type.
|
void |
setStepAdjustments(Collection<StepAdjustment> stepAdjustments)
A set of adjustments that enable you to scale based on the size of the alarm breach.
|
void |
setTargetTrackingConfiguration(TargetTrackingConfiguration targetTrackingConfiguration)
A target tracking scaling policy.
|
String |
toString()
Returns a string representation of this object.
|
PutScalingPolicyRequest |
withAdjustmentType(String adjustmentType)
Specifies how the scaling adjustment is interpreted (for example, an absolute number or a percentage).
|
PutScalingPolicyRequest |
withAutoScalingGroupName(String autoScalingGroupName)
The name of the Auto Scaling group.
|
PutScalingPolicyRequest |
withCooldown(Integer cooldown)
The duration of the policy's cooldown period, in seconds.
|
PutScalingPolicyRequest |
withEnabled(Boolean enabled)
Indicates whether the scaling policy is enabled or disabled.
|
PutScalingPolicyRequest |
withEstimatedInstanceWarmup(Integer estimatedInstanceWarmup)
The estimated time, in seconds, until a newly launched instance can contribute to the CloudWatch metrics.
|
PutScalingPolicyRequest |
withMetricAggregationType(String metricAggregationType)
The aggregation type for the CloudWatch metrics.
|
PutScalingPolicyRequest |
withMinAdjustmentMagnitude(Integer minAdjustmentMagnitude)
The minimum value to scale by when the adjustment type is
PercentChangeInCapacity . |
PutScalingPolicyRequest |
withMinAdjustmentStep(Integer minAdjustmentStep)
Available for backward compatibility.
|
PutScalingPolicyRequest |
withPolicyName(String policyName)
The name of the policy.
|
PutScalingPolicyRequest |
withPolicyType(String policyType)
One of the following policy types:
|
PutScalingPolicyRequest |
withScalingAdjustment(Integer scalingAdjustment)
The amount by which to scale, based on the specified adjustment type.
|
PutScalingPolicyRequest |
withStepAdjustments(Collection<StepAdjustment> stepAdjustments)
A set of adjustments that enable you to scale based on the size of the alarm breach.
|
PutScalingPolicyRequest |
withStepAdjustments(StepAdjustment... stepAdjustments)
A set of adjustments that enable you to scale based on the size of the alarm breach.
|
PutScalingPolicyRequest |
withTargetTrackingConfiguration(TargetTrackingConfiguration targetTrackingConfiguration)
A target tracking scaling policy.
|
addHandlerContext, getCloneRoot, getCloneSource, getCustomQueryParameters, getCustomRequestHeaders, getGeneralProgressListener, getHandlerContext, getReadLimit, getRequestClientOptions, getRequestCredentials, getRequestCredentialsProvider, getRequestMetricCollector, getSdkClientExecutionTimeout, getSdkRequestTimeout, putCustomQueryParameter, putCustomRequestHeader, setGeneralProgressListener, setRequestCredentials, setRequestCredentialsProvider, setRequestMetricCollector, setSdkClientExecutionTimeout, setSdkRequestTimeout, withGeneralProgressListener, withRequestCredentialsProvider, withRequestMetricCollector, withSdkClientExecutionTimeout, withSdkRequestTimeout
public void setAutoScalingGroupName(String autoScalingGroupName)
The name of the Auto Scaling group.
autoScalingGroupName
- The name of the Auto Scaling group.public String getAutoScalingGroupName()
The name of the Auto Scaling group.
public PutScalingPolicyRequest withAutoScalingGroupName(String autoScalingGroupName)
The name of the Auto Scaling group.
autoScalingGroupName
- The name of the Auto Scaling group.public void setPolicyName(String policyName)
The name of the policy.
policyName
- The name of the policy.public String getPolicyName()
The name of the policy.
public PutScalingPolicyRequest withPolicyName(String policyName)
The name of the policy.
policyName
- The name of the policy.public void setPolicyType(String policyType)
One of the following policy types:
TargetTrackingScaling
StepScaling
SimpleScaling
(default)
policyType
- One of the following policy types:
TargetTrackingScaling
StepScaling
SimpleScaling
(default)
public String getPolicyType()
One of the following policy types:
TargetTrackingScaling
StepScaling
SimpleScaling
(default)
TargetTrackingScaling
StepScaling
SimpleScaling
(default)
public PutScalingPolicyRequest withPolicyType(String policyType)
One of the following policy types:
TargetTrackingScaling
StepScaling
SimpleScaling
(default)
policyType
- One of the following policy types:
TargetTrackingScaling
StepScaling
SimpleScaling
(default)
public void setAdjustmentType(String adjustmentType)
Specifies how the scaling adjustment is interpreted (for example, an absolute number or a percentage). The valid
values are ChangeInCapacity
, ExactCapacity
, and PercentChangeInCapacity
.
Required if the policy type is StepScaling
or SimpleScaling
. For more information, see
Scaling adjustment types in the Amazon EC2 Auto Scaling User Guide.
adjustmentType
- Specifies how the scaling adjustment is interpreted (for example, an absolute number or a percentage). The
valid values are ChangeInCapacity
, ExactCapacity
, and
PercentChangeInCapacity
.
Required if the policy type is StepScaling
or SimpleScaling
. For more
information, see Scaling adjustment types in the Amazon EC2 Auto Scaling User Guide.
public String getAdjustmentType()
Specifies how the scaling adjustment is interpreted (for example, an absolute number or a percentage). The valid
values are ChangeInCapacity
, ExactCapacity
, and PercentChangeInCapacity
.
Required if the policy type is StepScaling
or SimpleScaling
. For more information, see
Scaling adjustment types in the Amazon EC2 Auto Scaling User Guide.
ChangeInCapacity
, ExactCapacity
, and
PercentChangeInCapacity
.
Required if the policy type is StepScaling
or SimpleScaling
. For more
information, see Scaling adjustment types in the Amazon EC2 Auto Scaling User Guide.
public PutScalingPolicyRequest withAdjustmentType(String adjustmentType)
Specifies how the scaling adjustment is interpreted (for example, an absolute number or a percentage). The valid
values are ChangeInCapacity
, ExactCapacity
, and PercentChangeInCapacity
.
Required if the policy type is StepScaling
or SimpleScaling
. For more information, see
Scaling adjustment types in the Amazon EC2 Auto Scaling User Guide.
adjustmentType
- Specifies how the scaling adjustment is interpreted (for example, an absolute number or a percentage). The
valid values are ChangeInCapacity
, ExactCapacity
, and
PercentChangeInCapacity
.
Required if the policy type is StepScaling
or SimpleScaling
. For more
information, see Scaling adjustment types in the Amazon EC2 Auto Scaling User Guide.
public void setMinAdjustmentStep(Integer minAdjustmentStep)
Available for backward compatibility. Use MinAdjustmentMagnitude
instead.
minAdjustmentStep
- Available for backward compatibility. Use MinAdjustmentMagnitude
instead.public Integer getMinAdjustmentStep()
Available for backward compatibility. Use MinAdjustmentMagnitude
instead.
MinAdjustmentMagnitude
instead.public PutScalingPolicyRequest withMinAdjustmentStep(Integer minAdjustmentStep)
Available for backward compatibility. Use MinAdjustmentMagnitude
instead.
minAdjustmentStep
- Available for backward compatibility. Use MinAdjustmentMagnitude
instead.public void setMinAdjustmentMagnitude(Integer minAdjustmentMagnitude)
The minimum value to scale by when the adjustment type is PercentChangeInCapacity
. For example,
suppose that you create a step scaling policy to scale out an Auto Scaling group by 25 percent and you specify a
MinAdjustmentMagnitude
of 2. If the group has 4 instances and the scaling policy is performed, 25
percent of 4 is 1. However, because you specified a MinAdjustmentMagnitude
of 2, Amazon EC2 Auto
Scaling scales out the group by 2 instances.
Valid only if the policy type is StepScaling
or SimpleScaling
. For more information,
see Scaling adjustment types in the Amazon EC2 Auto Scaling User Guide.
Some Auto Scaling groups use instance weights. In this case, set the MinAdjustmentMagnitude
to a
value that is at least as large as your largest instance weight.
minAdjustmentMagnitude
- The minimum value to scale by when the adjustment type is PercentChangeInCapacity
. For
example, suppose that you create a step scaling policy to scale out an Auto Scaling group by 25 percent
and you specify a MinAdjustmentMagnitude
of 2. If the group has 4 instances and the scaling
policy is performed, 25 percent of 4 is 1. However, because you specified a
MinAdjustmentMagnitude
of 2, Amazon EC2 Auto Scaling scales out the group by 2 instances.
Valid only if the policy type is StepScaling
or SimpleScaling
. For more
information, see Scaling adjustment types in the Amazon EC2 Auto Scaling User Guide.
Some Auto Scaling groups use instance weights. In this case, set the MinAdjustmentMagnitude
to a value that is at least as large as your largest instance weight.
public Integer getMinAdjustmentMagnitude()
The minimum value to scale by when the adjustment type is PercentChangeInCapacity
. For example,
suppose that you create a step scaling policy to scale out an Auto Scaling group by 25 percent and you specify a
MinAdjustmentMagnitude
of 2. If the group has 4 instances and the scaling policy is performed, 25
percent of 4 is 1. However, because you specified a MinAdjustmentMagnitude
of 2, Amazon EC2 Auto
Scaling scales out the group by 2 instances.
Valid only if the policy type is StepScaling
or SimpleScaling
. For more information,
see Scaling adjustment types in the Amazon EC2 Auto Scaling User Guide.
Some Auto Scaling groups use instance weights. In this case, set the MinAdjustmentMagnitude
to a
value that is at least as large as your largest instance weight.
PercentChangeInCapacity
. For
example, suppose that you create a step scaling policy to scale out an Auto Scaling group by 25 percent
and you specify a MinAdjustmentMagnitude
of 2. If the group has 4 instances and the scaling
policy is performed, 25 percent of 4 is 1. However, because you specified a
MinAdjustmentMagnitude
of 2, Amazon EC2 Auto Scaling scales out the group by 2
instances.
Valid only if the policy type is StepScaling
or SimpleScaling
. For more
information, see Scaling adjustment types in the Amazon EC2 Auto Scaling User Guide.
Some Auto Scaling groups use instance weights. In this case, set the MinAdjustmentMagnitude
to a value that is at least as large as your largest instance weight.
public PutScalingPolicyRequest withMinAdjustmentMagnitude(Integer minAdjustmentMagnitude)
The minimum value to scale by when the adjustment type is PercentChangeInCapacity
. For example,
suppose that you create a step scaling policy to scale out an Auto Scaling group by 25 percent and you specify a
MinAdjustmentMagnitude
of 2. If the group has 4 instances and the scaling policy is performed, 25
percent of 4 is 1. However, because you specified a MinAdjustmentMagnitude
of 2, Amazon EC2 Auto
Scaling scales out the group by 2 instances.
Valid only if the policy type is StepScaling
or SimpleScaling
. For more information,
see Scaling adjustment types in the Amazon EC2 Auto Scaling User Guide.
Some Auto Scaling groups use instance weights. In this case, set the MinAdjustmentMagnitude
to a
value that is at least as large as your largest instance weight.
minAdjustmentMagnitude
- The minimum value to scale by when the adjustment type is PercentChangeInCapacity
. For
example, suppose that you create a step scaling policy to scale out an Auto Scaling group by 25 percent
and you specify a MinAdjustmentMagnitude
of 2. If the group has 4 instances and the scaling
policy is performed, 25 percent of 4 is 1. However, because you specified a
MinAdjustmentMagnitude
of 2, Amazon EC2 Auto Scaling scales out the group by 2 instances.
Valid only if the policy type is StepScaling
or SimpleScaling
. For more
information, see Scaling adjustment types in the Amazon EC2 Auto Scaling User Guide.
Some Auto Scaling groups use instance weights. In this case, set the MinAdjustmentMagnitude
to a value that is at least as large as your largest instance weight.
public void setScalingAdjustment(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. For exact capacity, you must specify a positive value.
Required if the policy type is SimpleScaling
. (Not used with any other policy type.)
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. For exact capacity, you must specify a
positive value.
Required if the policy type is SimpleScaling
. (Not used with any other policy type.)
public Integer getScalingAdjustment()
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. For exact capacity, you must specify a positive value.
Required if the policy type is SimpleScaling
. (Not used with any other policy type.)
Required if the policy type is SimpleScaling
. (Not used with any other policy type.)
public PutScalingPolicyRequest withScalingAdjustment(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. For exact capacity, you must specify a positive value.
Required if the policy type is SimpleScaling
. (Not used with any other policy type.)
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. For exact capacity, you must specify a
positive value.
Required if the policy type is SimpleScaling
. (Not used with any other policy type.)
public void setCooldown(Integer cooldown)
The duration of the policy's cooldown period, in seconds. When a cooldown period is specified here, it overrides the default cooldown period defined for the Auto Scaling group.
Valid only if the policy type is SimpleScaling
. For more information, see Scaling cooldowns for Amazon EC2 Auto
Scaling in the Amazon EC2 Auto Scaling User Guide.
cooldown
- The duration of the policy's cooldown period, in seconds. When a cooldown period is specified here, it
overrides the default cooldown period defined for the Auto Scaling group.
Valid only if the policy type is SimpleScaling
. For more information, see Scaling cooldowns for Amazon
EC2 Auto Scaling in the Amazon EC2 Auto Scaling User Guide.
public Integer getCooldown()
The duration of the policy's cooldown period, in seconds. When a cooldown period is specified here, it overrides the default cooldown period defined for the Auto Scaling group.
Valid only if the policy type is SimpleScaling
. For more information, see Scaling cooldowns for Amazon EC2 Auto
Scaling in the Amazon EC2 Auto Scaling User Guide.
Valid only if the policy type is SimpleScaling
. For more information, see Scaling cooldowns for Amazon
EC2 Auto Scaling in the Amazon EC2 Auto Scaling User Guide.
public PutScalingPolicyRequest withCooldown(Integer cooldown)
The duration of the policy's cooldown period, in seconds. When a cooldown period is specified here, it overrides the default cooldown period defined for the Auto Scaling group.
Valid only if the policy type is SimpleScaling
. For more information, see Scaling cooldowns for Amazon EC2 Auto
Scaling in the Amazon EC2 Auto Scaling User Guide.
cooldown
- The duration of the policy's cooldown period, in seconds. When a cooldown period is specified here, it
overrides the default cooldown period defined for the Auto Scaling group.
Valid only if the policy type is SimpleScaling
. For more information, see Scaling cooldowns for Amazon
EC2 Auto Scaling in the Amazon EC2 Auto Scaling User Guide.
public void setMetricAggregationType(String metricAggregationType)
The aggregation type for the CloudWatch metrics. The valid values are Minimum
, Maximum
,
and Average
. If the aggregation type is null, the value is treated as Average
.
Valid only if the policy type is StepScaling
.
metricAggregationType
- The aggregation type for the CloudWatch metrics. The valid values are Minimum
,
Maximum
, and Average
. If the aggregation type is null, the value is treated as
Average
.
Valid only if the policy type is StepScaling
.
public String getMetricAggregationType()
The aggregation type for the CloudWatch metrics. The valid values are Minimum
, Maximum
,
and Average
. If the aggregation type is null, the value is treated as Average
.
Valid only if the policy type is StepScaling
.
Minimum
,
Maximum
, and Average
. If the aggregation type is null, the value is treated as
Average
.
Valid only if the policy type is StepScaling
.
public PutScalingPolicyRequest withMetricAggregationType(String metricAggregationType)
The aggregation type for the CloudWatch metrics. The valid values are Minimum
, Maximum
,
and Average
. If the aggregation type is null, the value is treated as Average
.
Valid only if the policy type is StepScaling
.
metricAggregationType
- The aggregation type for the CloudWatch metrics. The valid values are Minimum
,
Maximum
, and Average
. If the aggregation type is null, the value is treated as
Average
.
Valid only if the policy type is StepScaling
.
public List<StepAdjustment> getStepAdjustments()
A set of adjustments that enable you to scale based on the size of the alarm breach.
Required if the policy type is StepScaling
. (Not used with any other policy type.)
Required if the policy type is StepScaling
. (Not used with any other policy type.)
public void setStepAdjustments(Collection<StepAdjustment> stepAdjustments)
A set of adjustments that enable you to scale based on the size of the alarm breach.
Required if the policy type is StepScaling
. (Not used with any other policy type.)
stepAdjustments
- A set of adjustments that enable you to scale based on the size of the alarm breach.
Required if the policy type is StepScaling
. (Not used with any other policy type.)
public PutScalingPolicyRequest withStepAdjustments(StepAdjustment... stepAdjustments)
A set of adjustments that enable you to scale based on the size of the alarm breach.
Required if the policy type is StepScaling
. (Not used with any other policy type.)
NOTE: This method appends the values to the existing list (if any). Use
setStepAdjustments(java.util.Collection)
or withStepAdjustments(java.util.Collection)
if you
want to override the existing values.
stepAdjustments
- A set of adjustments that enable you to scale based on the size of the alarm breach.
Required if the policy type is StepScaling
. (Not used with any other policy type.)
public PutScalingPolicyRequest withStepAdjustments(Collection<StepAdjustment> stepAdjustments)
A set of adjustments that enable you to scale based on the size of the alarm breach.
Required if the policy type is StepScaling
. (Not used with any other policy type.)
stepAdjustments
- A set of adjustments that enable you to scale based on the size of the alarm breach.
Required if the policy type is StepScaling
. (Not used with any other policy type.)
public void setEstimatedInstanceWarmup(Integer estimatedInstanceWarmup)
The estimated time, in seconds, until a newly launched instance can contribute to the CloudWatch metrics. If not provided, the default is to use the value from the default cooldown period for the Auto Scaling group.
Valid only if the policy type is TargetTrackingScaling
or StepScaling
.
estimatedInstanceWarmup
- The estimated time, in seconds, until a newly launched instance can contribute to the CloudWatch metrics.
If not provided, the default is to use the value from the default cooldown period for the Auto Scaling
group.
Valid only if the policy type is TargetTrackingScaling
or StepScaling
.
public Integer getEstimatedInstanceWarmup()
The estimated time, in seconds, until a newly launched instance can contribute to the CloudWatch metrics. If not provided, the default is to use the value from the default cooldown period for the Auto Scaling group.
Valid only if the policy type is TargetTrackingScaling
or StepScaling
.
Valid only if the policy type is TargetTrackingScaling
or StepScaling
.
public PutScalingPolicyRequest withEstimatedInstanceWarmup(Integer estimatedInstanceWarmup)
The estimated time, in seconds, until a newly launched instance can contribute to the CloudWatch metrics. If not provided, the default is to use the value from the default cooldown period for the Auto Scaling group.
Valid only if the policy type is TargetTrackingScaling
or StepScaling
.
estimatedInstanceWarmup
- The estimated time, in seconds, until a newly launched instance can contribute to the CloudWatch metrics.
If not provided, the default is to use the value from the default cooldown period for the Auto Scaling
group.
Valid only if the policy type is TargetTrackingScaling
or StepScaling
.
public void setTargetTrackingConfiguration(TargetTrackingConfiguration targetTrackingConfiguration)
A target tracking scaling policy. Includes support for predefined or customized metrics.
The following predefined metrics are available:
ASGAverageCPUUtilization
ASGAverageNetworkIn
ASGAverageNetworkOut
ALBRequestCountPerTarget
If you specify ALBRequestCountPerTarget
for the metric, you must specify the
ResourceLabel
parameter with the PredefinedMetricSpecification
.
For more information, see TargetTrackingConfiguration in the Amazon EC2 Auto Scaling API Reference.
Required if the policy type is TargetTrackingScaling
.
targetTrackingConfiguration
- A target tracking scaling policy. Includes support for predefined or customized metrics.
The following predefined metrics are available:
ASGAverageCPUUtilization
ASGAverageNetworkIn
ASGAverageNetworkOut
ALBRequestCountPerTarget
If you specify ALBRequestCountPerTarget
for the metric, you must specify the
ResourceLabel
parameter with the PredefinedMetricSpecification
.
For more information, see TargetTrackingConfiguration in the Amazon EC2 Auto Scaling API Reference.
Required if the policy type is TargetTrackingScaling
.
public TargetTrackingConfiguration getTargetTrackingConfiguration()
A target tracking scaling policy. Includes support for predefined or customized metrics.
The following predefined metrics are available:
ASGAverageCPUUtilization
ASGAverageNetworkIn
ASGAverageNetworkOut
ALBRequestCountPerTarget
If you specify ALBRequestCountPerTarget
for the metric, you must specify the
ResourceLabel
parameter with the PredefinedMetricSpecification
.
For more information, see TargetTrackingConfiguration in the Amazon EC2 Auto Scaling API Reference.
Required if the policy type is TargetTrackingScaling
.
The following predefined metrics are available:
ASGAverageCPUUtilization
ASGAverageNetworkIn
ASGAverageNetworkOut
ALBRequestCountPerTarget
If you specify ALBRequestCountPerTarget
for the metric, you must specify the
ResourceLabel
parameter with the PredefinedMetricSpecification
.
For more information, see TargetTrackingConfiguration in the Amazon EC2 Auto Scaling API Reference.
Required if the policy type is TargetTrackingScaling
.
public PutScalingPolicyRequest withTargetTrackingConfiguration(TargetTrackingConfiguration targetTrackingConfiguration)
A target tracking scaling policy. Includes support for predefined or customized metrics.
The following predefined metrics are available:
ASGAverageCPUUtilization
ASGAverageNetworkIn
ASGAverageNetworkOut
ALBRequestCountPerTarget
If you specify ALBRequestCountPerTarget
for the metric, you must specify the
ResourceLabel
parameter with the PredefinedMetricSpecification
.
For more information, see TargetTrackingConfiguration in the Amazon EC2 Auto Scaling API Reference.
Required if the policy type is TargetTrackingScaling
.
targetTrackingConfiguration
- A target tracking scaling policy. Includes support for predefined or customized metrics.
The following predefined metrics are available:
ASGAverageCPUUtilization
ASGAverageNetworkIn
ASGAverageNetworkOut
ALBRequestCountPerTarget
If you specify ALBRequestCountPerTarget
for the metric, you must specify the
ResourceLabel
parameter with the PredefinedMetricSpecification
.
For more information, see TargetTrackingConfiguration in the Amazon EC2 Auto Scaling API Reference.
Required if the policy type is TargetTrackingScaling
.
public void setEnabled(Boolean enabled)
Indicates whether the scaling policy is enabled or disabled. The default is enabled. For more information, see Disabling a scaling policy for an Auto Scaling group in the Amazon EC2 Auto Scaling User Guide.
enabled
- Indicates whether the scaling policy is enabled or disabled. The default is enabled. For more information,
see
Disabling a scaling policy for an Auto Scaling group in the Amazon EC2 Auto Scaling User Guide.public Boolean getEnabled()
Indicates whether the scaling policy is enabled or disabled. The default is enabled. For more information, see Disabling a scaling policy for an Auto Scaling group in the Amazon EC2 Auto Scaling User Guide.
public PutScalingPolicyRequest withEnabled(Boolean enabled)
Indicates whether the scaling policy is enabled or disabled. The default is enabled. For more information, see Disabling a scaling policy for an Auto Scaling group in the Amazon EC2 Auto Scaling User Guide.
enabled
- Indicates whether the scaling policy is enabled or disabled. The default is enabled. For more information,
see
Disabling a scaling policy for an Auto Scaling group in the Amazon EC2 Auto Scaling User Guide.public Boolean isEnabled()
Indicates whether the scaling policy is enabled or disabled. The default is enabled. For more information, see Disabling a scaling policy for an Auto Scaling group in the Amazon EC2 Auto Scaling User Guide.
public String toString()
toString
in class Object
Object.toString()
public PutScalingPolicyRequest clone()
AmazonWebServiceRequest
clone
in class AmazonWebServiceRequest
Object.clone()