Class AutoScalingThresholds
- All Implemented Interfaces:
Serializable
,Cloneable
Describes a load-based auto scaling upscaling or downscaling threshold configuration, which specifies when AWS OpsWorks starts or stops load-based instances.
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionclone()
boolean
Custom Cloudwatch auto scaling alarms, to be used as thresholds.The CPU utilization threshold, as a percent of the available CPU.The amount of time (in minutes) after a scaling event occurs that AWS OpsWorks should ignore metrics and suppress additional scaling events.The number of instances to add or remove when the load exceeds a threshold.The load threshold.The memory utilization threshold, as a percent of the available memory.The amount of time, in minutes, that the load must exceed a threshold before more instances are added or removed.int
hashCode()
void
setAlarms
(Collection<String> alarms) Custom Cloudwatch auto scaling alarms, to be used as thresholds.void
setCpuThreshold
(Double cpuThreshold) The CPU utilization threshold, as a percent of the available CPU.void
setIgnoreMetricsTime
(Integer ignoreMetricsTime) The amount of time (in minutes) after a scaling event occurs that AWS OpsWorks should ignore metrics and suppress additional scaling events.void
setInstanceCount
(Integer instanceCount) The number of instances to add or remove when the load exceeds a threshold.void
setLoadThreshold
(Double loadThreshold) The load threshold.void
setMemoryThreshold
(Double memoryThreshold) The memory utilization threshold, as a percent of the available memory.void
setThresholdsWaitTime
(Integer thresholdsWaitTime) The amount of time, in minutes, that the load must exceed a threshold before more instances are added or removed.toString()
Returns a string representation of this object; useful for testing and debugging.withAlarms
(String... alarms) Custom Cloudwatch auto scaling alarms, to be used as thresholds.withAlarms
(Collection<String> alarms) Custom Cloudwatch auto scaling alarms, to be used as thresholds.withCpuThreshold
(Double cpuThreshold) The CPU utilization threshold, as a percent of the available CPU.withIgnoreMetricsTime
(Integer ignoreMetricsTime) The amount of time (in minutes) after a scaling event occurs that AWS OpsWorks should ignore metrics and suppress additional scaling events.withInstanceCount
(Integer instanceCount) The number of instances to add or remove when the load exceeds a threshold.withLoadThreshold
(Double loadThreshold) The load threshold.withMemoryThreshold
(Double memoryThreshold) The memory utilization threshold, as a percent of the available memory.withThresholdsWaitTime
(Integer thresholdsWaitTime) The amount of time, in minutes, that the load must exceed a threshold before more instances are added or removed.
-
Constructor Details
-
AutoScalingThresholds
public AutoScalingThresholds()
-
-
Method Details
-
setInstanceCount
The number of instances to add or remove when the load exceeds a threshold.
- Parameters:
instanceCount
- The number of instances to add or remove when the load exceeds a threshold.
-
getInstanceCount
The number of instances to add or remove when the load exceeds a threshold.
- Returns:
- The number of instances to add or remove when the load exceeds a threshold.
-
withInstanceCount
The number of instances to add or remove when the load exceeds a threshold.
- Parameters:
instanceCount
- The number of instances to add or remove when the load exceeds a threshold.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setThresholdsWaitTime
The amount of time, in minutes, that the load must exceed a threshold before more instances are added or removed.
- Parameters:
thresholdsWaitTime
- The amount of time, in minutes, that the load must exceed a threshold before more instances are added or removed.
-
getThresholdsWaitTime
The amount of time, in minutes, that the load must exceed a threshold before more instances are added or removed.
- Returns:
- The amount of time, in minutes, that the load must exceed a threshold before more instances are added or removed.
-
withThresholdsWaitTime
The amount of time, in minutes, that the load must exceed a threshold before more instances are added or removed.
- Parameters:
thresholdsWaitTime
- The amount of time, in minutes, that the load must exceed a threshold before more instances are added or removed.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setIgnoreMetricsTime
The amount of time (in minutes) after a scaling event occurs that AWS OpsWorks should ignore metrics and suppress additional scaling events. For example, AWS OpsWorks adds new instances following an upscaling event but the instances won't start reducing the load until they have been booted and configured. There is no point in raising additional scaling events during that operation, which typically takes several minutes.
IgnoreMetricsTime
allows you to direct AWS OpsWorks to suppress scaling events long enough to get the new instances online.- Parameters:
ignoreMetricsTime
- The amount of time (in minutes) after a scaling event occurs that AWS OpsWorks should ignore metrics and suppress additional scaling events. For example, AWS OpsWorks adds new instances following an upscaling event but the instances won't start reducing the load until they have been booted and configured. There is no point in raising additional scaling events during that operation, which typically takes several minutes.IgnoreMetricsTime
allows you to direct AWS OpsWorks to suppress scaling events long enough to get the new instances online.
-
getIgnoreMetricsTime
The amount of time (in minutes) after a scaling event occurs that AWS OpsWorks should ignore metrics and suppress additional scaling events. For example, AWS OpsWorks adds new instances following an upscaling event but the instances won't start reducing the load until they have been booted and configured. There is no point in raising additional scaling events during that operation, which typically takes several minutes.
IgnoreMetricsTime
allows you to direct AWS OpsWorks to suppress scaling events long enough to get the new instances online.- Returns:
- The amount of time (in minutes) after a scaling event occurs that
AWS OpsWorks should ignore metrics and suppress additional
scaling events. For example, AWS OpsWorks adds new instances
following an upscaling event but the instances won't start
reducing the load until they have been booted and configured.
There is no point in raising additional scaling events during
that operation, which typically takes several minutes.
IgnoreMetricsTime
allows you to direct AWS OpsWorks to suppress scaling events long enough to get the new instances online.
-
withIgnoreMetricsTime
The amount of time (in minutes) after a scaling event occurs that AWS OpsWorks should ignore metrics and suppress additional scaling events. For example, AWS OpsWorks adds new instances following an upscaling event but the instances won't start reducing the load until they have been booted and configured. There is no point in raising additional scaling events during that operation, which typically takes several minutes.
IgnoreMetricsTime
allows you to direct AWS OpsWorks to suppress scaling events long enough to get the new instances online.- Parameters:
ignoreMetricsTime
- The amount of time (in minutes) after a scaling event occurs that AWS OpsWorks should ignore metrics and suppress additional scaling events. For example, AWS OpsWorks adds new instances following an upscaling event but the instances won't start reducing the load until they have been booted and configured. There is no point in raising additional scaling events during that operation, which typically takes several minutes.IgnoreMetricsTime
allows you to direct AWS OpsWorks to suppress scaling events long enough to get the new instances online.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setCpuThreshold
The CPU utilization threshold, as a percent of the available CPU. A value of -1 disables the threshold.
- Parameters:
cpuThreshold
- The CPU utilization threshold, as a percent of the available CPU. A value of -1 disables the threshold.
-
getCpuThreshold
The CPU utilization threshold, as a percent of the available CPU. A value of -1 disables the threshold.
- Returns:
- The CPU utilization threshold, as a percent of the available CPU. A value of -1 disables the threshold.
-
withCpuThreshold
The CPU utilization threshold, as a percent of the available CPU. A value of -1 disables the threshold.
- Parameters:
cpuThreshold
- The CPU utilization threshold, as a percent of the available CPU. A value of -1 disables the threshold.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setMemoryThreshold
The memory utilization threshold, as a percent of the available memory. A value of -1 disables the threshold.
- Parameters:
memoryThreshold
- The memory utilization threshold, as a percent of the available memory. A value of -1 disables the threshold.
-
getMemoryThreshold
The memory utilization threshold, as a percent of the available memory. A value of -1 disables the threshold.
- Returns:
- The memory utilization threshold, as a percent of the available memory. A value of -1 disables the threshold.
-
withMemoryThreshold
The memory utilization threshold, as a percent of the available memory. A value of -1 disables the threshold.
- Parameters:
memoryThreshold
- The memory utilization threshold, as a percent of the available memory. A value of -1 disables the threshold.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setLoadThreshold
The load threshold. A value of -1 disables the threshold. For more information about how load is computed, see Load (computing).
- Parameters:
loadThreshold
- The load threshold. A value of -1 disables the threshold. For more information about how load is computed, see Load (computing).
-
getLoadThreshold
The load threshold. A value of -1 disables the threshold. For more information about how load is computed, see Load (computing).
- Returns:
- The load threshold. A value of -1 disables the threshold. For more information about how load is computed, see Load (computing).
-
withLoadThreshold
The load threshold. A value of -1 disables the threshold. For more information about how load is computed, see Load (computing).
- Parameters:
loadThreshold
- The load threshold. A value of -1 disables the threshold. For more information about how load is computed, see Load (computing).- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
getAlarms
Custom Cloudwatch auto scaling alarms, to be used as thresholds. This parameter takes a list of up to five alarm names, which are case sensitive and must be in the same region as the stack.
To use custom alarms, you must update your service role to allow cloudwatch:DescribeAlarms
. You can either have AWS OpsWorks update the role for you when you first use this feature or you can edit the role manually. For more information, see Allowing AWS OpsWorks to Act on Your Behalf.- Returns:
- Custom Cloudwatch auto scaling alarms, to be used as thresholds.
This parameter takes a list of up to five alarm names, which are
case sensitive and must be in the same region as the stack.
To use custom alarms, you must update your service role to allow cloudwatch:DescribeAlarms
. You can either have AWS OpsWorks update the role for you when you first use this feature or you can edit the role manually. For more information, see Allowing AWS OpsWorks to Act on Your Behalf.
-
setAlarms
Custom Cloudwatch auto scaling alarms, to be used as thresholds. This parameter takes a list of up to five alarm names, which are case sensitive and must be in the same region as the stack.
To use custom alarms, you must update your service role to allow cloudwatch:DescribeAlarms
. You can either have AWS OpsWorks update the role for you when you first use this feature or you can edit the role manually. For more information, see Allowing AWS OpsWorks to Act on Your Behalf.- Parameters:
alarms
- Custom Cloudwatch auto scaling alarms, to be used as thresholds. This parameter takes a list of up to five alarm names, which are case sensitive and must be in the same region as the stack.To use custom alarms, you must update your service role to allow cloudwatch:DescribeAlarms
. You can either have AWS OpsWorks update the role for you when you first use this feature or you can edit the role manually. For more information, see Allowing AWS OpsWorks to Act on Your Behalf.
-
withAlarms
Custom Cloudwatch auto scaling alarms, to be used as thresholds. This parameter takes a list of up to five alarm names, which are case sensitive and must be in the same region as the stack.
To use custom alarms, you must update your service role to allow cloudwatch:DescribeAlarms
. You can either have AWS OpsWorks update the role for you when you first use this feature or you can edit the role manually. For more information, see Allowing AWS OpsWorks to Act on Your Behalf.NOTE: This method appends the values to the existing list (if any). Use
setAlarms(java.util.Collection)
orwithAlarms(java.util.Collection)
if you want to override the existing values.- Parameters:
alarms
- Custom Cloudwatch auto scaling alarms, to be used as thresholds. This parameter takes a list of up to five alarm names, which are case sensitive and must be in the same region as the stack.To use custom alarms, you must update your service role to allow cloudwatch:DescribeAlarms
. You can either have AWS OpsWorks update the role for you when you first use this feature or you can edit the role manually. For more information, see Allowing AWS OpsWorks to Act on Your Behalf.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
withAlarms
Custom Cloudwatch auto scaling alarms, to be used as thresholds. This parameter takes a list of up to five alarm names, which are case sensitive and must be in the same region as the stack.
To use custom alarms, you must update your service role to allow cloudwatch:DescribeAlarms
. You can either have AWS OpsWorks update the role for you when you first use this feature or you can edit the role manually. For more information, see Allowing AWS OpsWorks to Act on Your Behalf.- Parameters:
alarms
- Custom Cloudwatch auto scaling alarms, to be used as thresholds. This parameter takes a list of up to five alarm names, which are case sensitive and must be in the same region as the stack.To use custom alarms, you must update your service role to allow cloudwatch:DescribeAlarms
. You can either have AWS OpsWorks update the role for you when you first use this feature or you can edit the role manually. For more information, see Allowing AWS OpsWorks to Act on Your Behalf.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
toString
Returns a string representation of this object; useful for testing and debugging. -
equals
-
hashCode
public int hashCode() -
clone
-