public static interface ScaleRule.Update extends Settable<AutoscaleProfile.Update>
Modifier and Type | Method and Description |
---|---|
ScaleRule.Update |
withCondition(TimeAggregationType timeAggregation,
ComparisonOperationType condition,
double threshold)
Updates the condition to monitor for the current metric alert.
|
ScaleRule.Update |
withMetricName(String metricName)
the name of the metric that defines what the rule monitors.
|
ScaleRule.Update |
withMetricSource(String metricSourceResourceId)
Updates the resource identifier of the resource the rule monitors.
|
ScaleRule.Update |
withScaleAction(ScaleDirection direction,
ScaleType type,
int instanceCountChange,
org.joda.time.Period cooldown)
Updates the action to be performed when the scale rule will be active.
|
ScaleRule.Update |
withStatistic()
Sets statistics for autoscale trigger action with default values of 10 minutes for duration, 1 minute for frequency(time grain) and 'Average' for statistic type.
|
ScaleRule.Update |
withStatistic(org.joda.time.Period duration)
Sets statistics for autoscale trigger action with default values of 1 minute for frequency(time grain) and 'Average' for statistic type.
|
ScaleRule.Update |
withStatistic(org.joda.time.Period duration,
MetricStatisticType statisticType)
Sets statistics for autoscale trigger action with default values of 1 minute for frequency(time grain).
|
ScaleRule.Update |
withStatistic(org.joda.time.Period duration,
org.joda.time.Period frequency,
MetricStatisticType statisticType)
Updates the statistics for autoscale trigger action.
|
ScaleRule.Update withMetricSource(String metricSourceResourceId)
metricSourceResourceId
- resourceId of the resource.ScaleRule.Update withMetricName(String metricName)
metricName
- metricName name of the metric.ScaleRule.Update withStatistic(org.joda.time.Period duration, org.joda.time.Period frequency, MetricStatisticType statisticType)
duration
- the range of time in which instance data is collected. This value must be greater than the delay in metric collection, which can vary from resource-to-resource. Must be between 12 hours and 5 minutes.frequency
- the granularity of metrics the rule monitors. Must be one of the predefined values returned from metric definitions for the metric. Must be between 12 hours and 1 minute.statisticType
- the metric statistic type. How the metrics from multiple instances are combined. Possible values include: 'Average', 'Min', 'Max', 'Sum'.ScaleRule.Update withStatistic()
ScaleRule.Update withStatistic(org.joda.time.Period duration)
duration
- the range of time in which instance data is collected. This value must be greater than the delay in metric collection, which can vary from resource-to-resource. Must be between 12 hours and 5 minutes.ScaleRule.Update withStatistic(org.joda.time.Period duration, MetricStatisticType statisticType)
duration
- the range of time in which instance data is collected. This value must be greater than the delay in metric collection, which can vary from resource-to-resource. Must be between 12 hours and 5 minutes.statisticType
- the metric statistic type. How the metrics from multiple instances are combined. Possible values include: 'Average', 'Min', 'Max', 'Sum'.ScaleRule.Update withCondition(TimeAggregationType timeAggregation, ComparisonOperationType condition, double threshold)
condition
- the operator that is used to compare the metric data and the threshold. Possible values include: 'Equals', 'NotEquals', 'GreaterThan', 'GreaterThanOrEqual', 'LessThan', 'LessThanOrEqual'.timeAggregation
- the time aggregation type. How the data that is collected should be combined over time. The default value is Average. Possible values include: 'Average', 'Minimum', 'Maximum', 'Total', 'Count'.threshold
- the threshold of the metric that triggers the scale action.ScaleRule.Update withScaleAction(ScaleDirection direction, ScaleType type, int instanceCountChange, org.joda.time.Period cooldown)
direction
- the scale direction. Whether the scaling action increases or decreases the number of instances. Possible values include: 'None', 'Increase', 'Decrease'.type
- the type of action that should occur when the scale rule fires. Possible values include: 'ChangeCount', 'PercentChangeCount', 'ExactCount'.instanceCountChange
- the number of instances that are involved in the scaling action.cooldown
- the amount of time to wait since the last scaling action before this action occurs. It must be between 1 week and 1 minute in ISO 8601 format.Copyright © 2019. All rights reserved.