Class CloudWatchAlarmConfiguration
- java.lang.Object
-
- com.amazonaws.services.route53.model.CloudWatchAlarmConfiguration
-
- All Implemented Interfaces:
Serializable
,Cloneable
public class CloudWatchAlarmConfiguration extends Object implements Serializable, Cloneable
For CLOUDWATCH_METRIC health checks, a complex type that contains information about the CloudWatch alarm that you're associating with the health check.
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description CloudWatchAlarmConfiguration()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description CloudWatchAlarmConfiguration
clone()
boolean
equals(Object obj)
String
getComparisonOperator()
The arithmetic operation to use when comparing the specified Statistic and Threshold.List<Dimension>
getDimensions()
A list ofDimension
elements for the CloudWatch metric that is associated with the CloudWatch alarm.Integer
getEvaluationPeriods()
The number of periods over which data is compared to the specified threshold.String
getMetricName()
The name of the CloudWatch metric that is associated with the CloudWatch alarm.String
getNamespace()
The namespace of the CloudWatch metric that is associated with the CloudWatch alarm.Integer
getPeriod()
An integer that represents the period in seconds over which the statistic is applied.String
getStatistic()
The statistic to apply to the CloudWatch metric that is associated with the CloudWatch alarm.Double
getThreshold()
The value that the metric is compared with to determine the state of the alarm.int
hashCode()
void
setComparisonOperator(ComparisonOperator comparisonOperator)
The arithmetic operation to use when comparing the specified Statistic and Threshold.void
setComparisonOperator(String comparisonOperator)
The arithmetic operation to use when comparing the specified Statistic and Threshold.void
setDimensions(Collection<Dimension> dimensions)
A list ofDimension
elements for the CloudWatch metric that is associated with the CloudWatch alarm.void
setEvaluationPeriods(Integer evaluationPeriods)
The number of periods over which data is compared to the specified threshold.void
setMetricName(String metricName)
The name of the CloudWatch metric that is associated with the CloudWatch alarm.void
setNamespace(String namespace)
The namespace of the CloudWatch metric that is associated with the CloudWatch alarm.void
setPeriod(Integer period)
An integer that represents the period in seconds over which the statistic is applied.void
setStatistic(Statistic statistic)
The statistic to apply to the CloudWatch metric that is associated with the CloudWatch alarm.void
setStatistic(String statistic)
The statistic to apply to the CloudWatch metric that is associated with the CloudWatch alarm.void
setThreshold(Double threshold)
The value that the metric is compared with to determine the state of the alarm.String
toString()
Returns a string representation of this object; useful for testing and debugging.CloudWatchAlarmConfiguration
withComparisonOperator(ComparisonOperator comparisonOperator)
The arithmetic operation to use when comparing the specified Statistic and Threshold.CloudWatchAlarmConfiguration
withComparisonOperator(String comparisonOperator)
The arithmetic operation to use when comparing the specified Statistic and Threshold.CloudWatchAlarmConfiguration
withDimensions(Dimension... dimensions)
A list ofDimension
elements for the CloudWatch metric that is associated with the CloudWatch alarm.CloudWatchAlarmConfiguration
withDimensions(Collection<Dimension> dimensions)
A list ofDimension
elements for the CloudWatch metric that is associated with the CloudWatch alarm.CloudWatchAlarmConfiguration
withEvaluationPeriods(Integer evaluationPeriods)
The number of periods over which data is compared to the specified threshold.CloudWatchAlarmConfiguration
withMetricName(String metricName)
The name of the CloudWatch metric that is associated with the CloudWatch alarm.CloudWatchAlarmConfiguration
withNamespace(String namespace)
The namespace of the CloudWatch metric that is associated with the CloudWatch alarm.CloudWatchAlarmConfiguration
withPeriod(Integer period)
An integer that represents the period in seconds over which the statistic is applied.CloudWatchAlarmConfiguration
withStatistic(Statistic statistic)
The statistic to apply to the CloudWatch metric that is associated with the CloudWatch alarm.CloudWatchAlarmConfiguration
withStatistic(String statistic)
The statistic to apply to the CloudWatch metric that is associated with the CloudWatch alarm.CloudWatchAlarmConfiguration
withThreshold(Double threshold)
The value that the metric is compared with to determine the state of the alarm.
-
-
-
Method Detail
-
setEvaluationPeriods
public void setEvaluationPeriods(Integer evaluationPeriods)
The number of periods over which data is compared to the specified threshold.
- Parameters:
evaluationPeriods
- The number of periods over which data is compared to the specified threshold.
-
getEvaluationPeriods
public Integer getEvaluationPeriods()
The number of periods over which data is compared to the specified threshold.
- Returns:
- The number of periods over which data is compared to the specified threshold.
-
withEvaluationPeriods
public CloudWatchAlarmConfiguration withEvaluationPeriods(Integer evaluationPeriods)
The number of periods over which data is compared to the specified threshold.
- Parameters:
evaluationPeriods
- The number of periods over which data is compared to the specified threshold.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setThreshold
public void setThreshold(Double threshold)
The value that the metric is compared with to determine the state of the alarm. For example, if you want the health check to fail if the average TCP connection time is greater than 500 milliseconds for more than 60 seconds, the threshold is 500.
- Parameters:
threshold
- The value that the metric is compared with to determine the state of the alarm. For example, if you want the health check to fail if the average TCP connection time is greater than 500 milliseconds for more than 60 seconds, the threshold is 500.
-
getThreshold
public Double getThreshold()
The value that the metric is compared with to determine the state of the alarm. For example, if you want the health check to fail if the average TCP connection time is greater than 500 milliseconds for more than 60 seconds, the threshold is 500.
- Returns:
- The value that the metric is compared with to determine the state of the alarm. For example, if you want the health check to fail if the average TCP connection time is greater than 500 milliseconds for more than 60 seconds, the threshold is 500.
-
withThreshold
public CloudWatchAlarmConfiguration withThreshold(Double threshold)
The value that the metric is compared with to determine the state of the alarm. For example, if you want the health check to fail if the average TCP connection time is greater than 500 milliseconds for more than 60 seconds, the threshold is 500.
- Parameters:
threshold
- The value that the metric is compared with to determine the state of the alarm. For example, if you want the health check to fail if the average TCP connection time is greater than 500 milliseconds for more than 60 seconds, the threshold is 500.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setComparisonOperator
public void setComparisonOperator(String comparisonOperator)
The arithmetic operation to use when comparing the specified Statistic and Threshold.
Valid Values are
GreaterThanOrEqualToThreshold
,GreaterThanThreshold
,LessThanThreshold
andLessThanOrEqualToThreshold
- Parameters:
comparisonOperator
- The arithmetic operation to use when comparing the specified Statistic and Threshold.Valid Values are
GreaterThanOrEqualToThreshold
,GreaterThanThreshold
,LessThanThreshold
andLessThanOrEqualToThreshold
- See Also:
ComparisonOperator
-
getComparisonOperator
public String getComparisonOperator()
The arithmetic operation to use when comparing the specified Statistic and Threshold.
Valid Values are
GreaterThanOrEqualToThreshold
,GreaterThanThreshold
,LessThanThreshold
andLessThanOrEqualToThreshold
- Returns:
- The arithmetic operation to use when comparing the specified
Statistic and Threshold.
Valid Values are
GreaterThanOrEqualToThreshold
,GreaterThanThreshold
,LessThanThreshold
andLessThanOrEqualToThreshold
- See Also:
ComparisonOperator
-
withComparisonOperator
public CloudWatchAlarmConfiguration withComparisonOperator(String comparisonOperator)
The arithmetic operation to use when comparing the specified Statistic and Threshold.
Valid Values are
GreaterThanOrEqualToThreshold
,GreaterThanThreshold
,LessThanThreshold
andLessThanOrEqualToThreshold
- Parameters:
comparisonOperator
- The arithmetic operation to use when comparing the specified Statistic and Threshold.Valid Values are
GreaterThanOrEqualToThreshold
,GreaterThanThreshold
,LessThanThreshold
andLessThanOrEqualToThreshold
- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
ComparisonOperator
-
setComparisonOperator
public void setComparisonOperator(ComparisonOperator comparisonOperator)
The arithmetic operation to use when comparing the specified Statistic and Threshold.
Valid Values are
GreaterThanOrEqualToThreshold
,GreaterThanThreshold
,LessThanThreshold
andLessThanOrEqualToThreshold
- Parameters:
comparisonOperator
- The arithmetic operation to use when comparing the specified Statistic and Threshold.Valid Values are
GreaterThanOrEqualToThreshold
,GreaterThanThreshold
,LessThanThreshold
andLessThanOrEqualToThreshold
- See Also:
ComparisonOperator
-
withComparisonOperator
public CloudWatchAlarmConfiguration withComparisonOperator(ComparisonOperator comparisonOperator)
The arithmetic operation to use when comparing the specified Statistic and Threshold.
Valid Values are
GreaterThanOrEqualToThreshold
,GreaterThanThreshold
,LessThanThreshold
andLessThanOrEqualToThreshold
- Parameters:
comparisonOperator
- The arithmetic operation to use when comparing the specified Statistic and Threshold.Valid Values are
GreaterThanOrEqualToThreshold
,GreaterThanThreshold
,LessThanThreshold
andLessThanOrEqualToThreshold
- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
ComparisonOperator
-
setPeriod
public void setPeriod(Integer period)
An integer that represents the period in seconds over which the statistic is applied.
- Parameters:
period
- An integer that represents the period in seconds over which the statistic is applied.
-
getPeriod
public Integer getPeriod()
An integer that represents the period in seconds over which the statistic is applied.
- Returns:
- An integer that represents the period in seconds over which the statistic is applied.
-
withPeriod
public CloudWatchAlarmConfiguration withPeriod(Integer period)
An integer that represents the period in seconds over which the statistic is applied.
- Parameters:
period
- An integer that represents the period in seconds over which the statistic is applied.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setMetricName
public void setMetricName(String metricName)
The name of the CloudWatch metric that is associated with the CloudWatch alarm.
- Parameters:
metricName
- The name of the CloudWatch metric that is associated with the CloudWatch alarm.
-
getMetricName
public String getMetricName()
The name of the CloudWatch metric that is associated with the CloudWatch alarm.
- Returns:
- The name of the CloudWatch metric that is associated with the CloudWatch alarm.
-
withMetricName
public CloudWatchAlarmConfiguration withMetricName(String metricName)
The name of the CloudWatch metric that is associated with the CloudWatch alarm.
- Parameters:
metricName
- The name of the CloudWatch metric that is associated with the CloudWatch alarm.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setNamespace
public void setNamespace(String namespace)
The namespace of the CloudWatch metric that is associated with the CloudWatch alarm.
- Parameters:
namespace
- The namespace of the CloudWatch metric that is associated with the CloudWatch alarm.
-
getNamespace
public String getNamespace()
The namespace of the CloudWatch metric that is associated with the CloudWatch alarm.
- Returns:
- The namespace of the CloudWatch metric that is associated with the CloudWatch alarm.
-
withNamespace
public CloudWatchAlarmConfiguration withNamespace(String namespace)
The namespace of the CloudWatch metric that is associated with the CloudWatch alarm.
- Parameters:
namespace
- The namespace of the CloudWatch metric that is associated with the CloudWatch alarm.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setStatistic
public void setStatistic(String statistic)
The statistic to apply to the CloudWatch metric that is associated with the CloudWatch alarm.
Valid Values are
SampleCount
,Average
,Sum
,Minimum
andMaximum
- Parameters:
statistic
- The statistic to apply to the CloudWatch metric that is associated with the CloudWatch alarm.Valid Values are
SampleCount
,Average
,Sum
,Minimum
andMaximum
- See Also:
Statistic
-
getStatistic
public String getStatistic()
The statistic to apply to the CloudWatch metric that is associated with the CloudWatch alarm.
Valid Values are
SampleCount
,Average
,Sum
,Minimum
andMaximum
- Returns:
- The statistic to apply to the CloudWatch metric that is
associated with the CloudWatch alarm.
Valid Values are
SampleCount
,Average
,Sum
,Minimum
andMaximum
- See Also:
Statistic
-
withStatistic
public CloudWatchAlarmConfiguration withStatistic(String statistic)
The statistic to apply to the CloudWatch metric that is associated with the CloudWatch alarm.
Valid Values are
SampleCount
,Average
,Sum
,Minimum
andMaximum
- Parameters:
statistic
- The statistic to apply to the CloudWatch metric that is associated with the CloudWatch alarm.Valid Values are
SampleCount
,Average
,Sum
,Minimum
andMaximum
- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
Statistic
-
setStatistic
public void setStatistic(Statistic statistic)
The statistic to apply to the CloudWatch metric that is associated with the CloudWatch alarm.
Valid Values are
SampleCount
,Average
,Sum
,Minimum
andMaximum
- Parameters:
statistic
- The statistic to apply to the CloudWatch metric that is associated with the CloudWatch alarm.Valid Values are
SampleCount
,Average
,Sum
,Minimum
andMaximum
- See Also:
Statistic
-
withStatistic
public CloudWatchAlarmConfiguration withStatistic(Statistic statistic)
The statistic to apply to the CloudWatch metric that is associated with the CloudWatch alarm.
Valid Values are
SampleCount
,Average
,Sum
,Minimum
andMaximum
- Parameters:
statistic
- The statistic to apply to the CloudWatch metric that is associated with the CloudWatch alarm.Valid Values are
SampleCount
,Average
,Sum
,Minimum
andMaximum
- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
Statistic
-
getDimensions
public List<Dimension> getDimensions()
A list of
Dimension
elements for the CloudWatch metric that is associated with the CloudWatch alarm. For information about the metrics and dimensions that CloudWatch supports, see Amazon CloudWatch Namespaces, Dimensions, and Metrics Reference.- Returns:
- A list of
Dimension
elements for the CloudWatch metric that is associated with the CloudWatch alarm. For information about the metrics and dimensions that CloudWatch supports, see Amazon CloudWatch Namespaces, Dimensions, and Metrics Reference.
-
setDimensions
public void setDimensions(Collection<Dimension> dimensions)
A list of
Dimension
elements for the CloudWatch metric that is associated with the CloudWatch alarm. For information about the metrics and dimensions that CloudWatch supports, see Amazon CloudWatch Namespaces, Dimensions, and Metrics Reference.- Parameters:
dimensions
- A list ofDimension
elements for the CloudWatch metric that is associated with the CloudWatch alarm. For information about the metrics and dimensions that CloudWatch supports, see Amazon CloudWatch Namespaces, Dimensions, and Metrics Reference.
-
withDimensions
public CloudWatchAlarmConfiguration withDimensions(Dimension... dimensions)
A list of
Dimension
elements for the CloudWatch metric that is associated with the CloudWatch alarm. For information about the metrics and dimensions that CloudWatch supports, see Amazon CloudWatch Namespaces, Dimensions, and Metrics Reference.NOTE: This method appends the values to the existing list (if any). Use
setDimensions(java.util.Collection)
orwithDimensions(java.util.Collection)
if you want to override the existing values.- Parameters:
dimensions
- A list ofDimension
elements for the CloudWatch metric that is associated with the CloudWatch alarm. For information about the metrics and dimensions that CloudWatch supports, see Amazon CloudWatch Namespaces, Dimensions, and Metrics Reference.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
withDimensions
public CloudWatchAlarmConfiguration withDimensions(Collection<Dimension> dimensions)
A list of
Dimension
elements for the CloudWatch metric that is associated with the CloudWatch alarm. For information about the metrics and dimensions that CloudWatch supports, see Amazon CloudWatch Namespaces, Dimensions, and Metrics Reference.- Parameters:
dimensions
- A list ofDimension
elements for the CloudWatch metric that is associated with the CloudWatch alarm. For information about the metrics and dimensions that CloudWatch supports, see Amazon CloudWatch Namespaces, Dimensions, and Metrics Reference.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
toString
public String toString()
Returns a string representation of this object; useful for testing and debugging.- Overrides:
toString
in classObject
- Returns:
- A string representation of this object.
- See Also:
Object.toString()
-
clone
public CloudWatchAlarmConfiguration clone()
-
-