public class PutResourceMetricRuleShrinkRequest
extends com.aliyun.tea.TeaModel
| 限定符和类型 | 字段和说明 |
|---|---|
String |
compositeExpressionShrink
The trigger conditions for multiple metrics.
|
String |
contactGroups
The alert contact group.
|
String |
effectiveInterval
The time period during which the alert rule is effective.
|
String |
emailSubject
The subject of the alert notification email.
|
PutResourceMetricRuleShrinkRequest.PutResourceMetricRuleShrinkRequestEscalations |
escalations |
String |
interval
The interval at which the alert is triggered.
|
List<PutResourceMetricRuleShrinkRequest.PutResourceMetricRuleShrinkRequestLabels> |
labels
The tags.
|
String |
metricName
The name of the metric.
|
String |
namespace
The namespace of the cloud service.
|
String |
noDataPolicy
The processing method of alerts when no monitoring data is found.
|
String |
noEffectiveInterval
The time period during which the alert rule is ineffective.
|
String |
period
The statistical period of the metric.
|
String |
prometheusShrink
The Prometheus alert rule.
|
String |
resources
The information about the resource.
|
String |
ruleId
The ID of the alert rule.
|
String |
ruleName
The name of the alert rule.
|
Integer |
silenceTime
The mute period during which new alerts are not sent even if the trigger conditions are met.
|
String |
webhook
The callback URL to which a POST request is sent when an alert is triggered based on the alert rule.
|
| 构造器和说明 |
|---|
PutResourceMetricRuleShrinkRequest() |
@NameInMap(value="Escalations") public PutResourceMetricRuleShrinkRequest.PutResourceMetricRuleShrinkRequestEscalations escalations
@NameInMap(value="CompositeExpression") public String compositeExpressionShrink
The trigger conditions for multiple metrics.
> The trigger conditions for a single metric and multiple metrics are mutually exclusive. You cannot specify trigger conditions for a single metric and multiple metrics at the same time.
@NameInMap(value="ContactGroups") public String contactGroups
The alert contact group. The alert notifications are sent to the contacts that belong to the alert contact group.
> An alert contact group can contain one or more alert contacts. For information about how to create alert contacts and alert contact groups, see [PutContact](~~114923~~) and [PutContactGroup](~~114929~~).
@NameInMap(value="EffectiveInterval") public String effectiveInterval
The time period during which the alert rule is effective.
@NameInMap(value="EmailSubject") public String emailSubject
The subject of the alert notification email.
@NameInMap(value="Interval") public String interval
The interval at which the alert is triggered. Unit: seconds.
> For information about how to query the statistical period of a metric, see [Appendix 1: Metrics](~~163515~~).
@NameInMap(value="Labels") public List<PutResourceMetricRuleShrinkRequest.PutResourceMetricRuleShrinkRequestLabels> labels
The tags.
@NameInMap(value="MetricName") public String metricName
The name of the metric. For information about how to query the name of a metric, see [Appendix 1: Metrics](~~163515~~).
> If you create a Prometheus alert rule for Hybrid Cloud Monitoring, you must set this parameter to the name of the namespace. For information about how to obtain the name of a namespace, see [DescribeHybridMonitorNamespaceList](~~428880~~).
@NameInMap(value="Namespace") public String namespace
The namespace of the cloud service. For information about how to query the namespace of a cloud service, see [Appendix 1: Metrics](~~163515~~).
> If you create a Prometheus alert rule for Hybrid Cloud Monitoring, you must set this parameter to `acs_prometheus`.
@NameInMap(value="NoDataPolicy") public String noDataPolicy
The processing method of alerts when no monitoring data is found. Valid values:
* KEEP_LAST_STATE (default value): No operation is performed.
* INSUFFICIENT_DATA: An alert whose content is "Insufficient data" is triggered.
* OK: The status is considered normal.
@NameInMap(value="NoEffectiveInterval") public String noEffectiveInterval
The time period during which the alert rule is ineffective.
@NameInMap(value="Period") public String period
The statistical period of the metric. Unit: seconds. The default value is the interval at which the monitoring data of the metric is collected.
> For information about how to query the statistical period of a metric, see [Appendix 1: Metrics](~~163515~~).
@NameInMap(value="Prometheus") public String prometheusShrink
The Prometheus alert rule.
> This parameter is required only when you create a Prometheus alert rule for Hybrid Cloud Monitoring.
@NameInMap(value="Resources") public String resources
The information about the resource. Examples: `[{"instanceId":"i-uf6j91r34rnwawoo****"}]` and `[{"userId":"100931896542****"}]`.
For information about the supported dimensions that are used to query resources, see [Appendix 1: Metrics](~~163515~~).
@NameInMap(value="RuleId") public String ruleId
The ID of the alert rule.
You can specify a new ID or the ID of an existing alert rule. For information about how to query the ID of an alert rule, see [DescribeMetricRuleList](~~114941~~).
> If you specify a new ID, a threshold-triggered alert rule is created.
@NameInMap(value="RuleName") public String ruleName
The name of the alert rule.
You can specify a new name or the name of an existing alert rule. For information about how to query the name of an alert rule, see [DescribeMetricRuleList](~~114941~~).
> If you specify a new name, a threshold-triggered alert rule is created.
@NameInMap(value="SilenceTime") public Integer silenceTime
The mute period during which new alerts are not sent even if the trigger conditions are met. Unit: seconds. Default value: 86400.
> If an alert is not cleared within the mute period, a new alert notification is sent when the mute period ends.
@NameInMap(value="Webhook") public String webhook
The callback URL to which a POST request is sent when an alert is triggered based on the alert rule.
public static PutResourceMetricRuleShrinkRequest build(Map<String,?> map) throws Exception
Exceptionpublic PutResourceMetricRuleShrinkRequest setEscalations(PutResourceMetricRuleShrinkRequest.PutResourceMetricRuleShrinkRequestEscalations escalations)
public PutResourceMetricRuleShrinkRequest.PutResourceMetricRuleShrinkRequestEscalations getEscalations()
public PutResourceMetricRuleShrinkRequest setCompositeExpressionShrink(String compositeExpressionShrink)
public String getCompositeExpressionShrink()
public PutResourceMetricRuleShrinkRequest setContactGroups(String contactGroups)
public String getContactGroups()
public PutResourceMetricRuleShrinkRequest setEffectiveInterval(String effectiveInterval)
public String getEffectiveInterval()
public PutResourceMetricRuleShrinkRequest setEmailSubject(String emailSubject)
public String getEmailSubject()
public PutResourceMetricRuleShrinkRequest setInterval(String interval)
public String getInterval()
public PutResourceMetricRuleShrinkRequest setLabels(List<PutResourceMetricRuleShrinkRequest.PutResourceMetricRuleShrinkRequestLabels> labels)
public List<PutResourceMetricRuleShrinkRequest.PutResourceMetricRuleShrinkRequestLabels> getLabels()
public PutResourceMetricRuleShrinkRequest setMetricName(String metricName)
public String getMetricName()
public PutResourceMetricRuleShrinkRequest setNamespace(String namespace)
public String getNamespace()
public PutResourceMetricRuleShrinkRequest setNoDataPolicy(String noDataPolicy)
public String getNoDataPolicy()
public PutResourceMetricRuleShrinkRequest setNoEffectiveInterval(String noEffectiveInterval)
public String getNoEffectiveInterval()
public PutResourceMetricRuleShrinkRequest setPeriod(String period)
public String getPeriod()
public PutResourceMetricRuleShrinkRequest setPrometheusShrink(String prometheusShrink)
public String getPrometheusShrink()
public PutResourceMetricRuleShrinkRequest setResources(String resources)
public String getResources()
public PutResourceMetricRuleShrinkRequest setRuleId(String ruleId)
public String getRuleId()
public PutResourceMetricRuleShrinkRequest setRuleName(String ruleName)
public String getRuleName()
public PutResourceMetricRuleShrinkRequest setSilenceTime(Integer silenceTime)
public Integer getSilenceTime()
public PutResourceMetricRuleShrinkRequest setWebhook(String webhook)
public String getWebhook()
Copyright © 2024. All rights reserved.