public static class PutResourceMetricRulesRequest.PutResourceMetricRulesRequestRules
extends com.aliyun.tea.TeaModel
| 限定符和类型 | 字段和说明 |
|---|---|
String |
contactGroups
The alert contact groups.
|
String |
effectiveInterval
The time period during which the alert rule is effective.
|
String |
emailSubject
The subject of the alert notification email.
|
PutResourceMetricRulesRequest.PutResourceMetricRulesRequestRulesEscalations |
escalations |
String |
interval
The interval at which alerts are triggered based on the alert rule.
|
List<PutResourceMetricRulesRequest.PutResourceMetricRulesRequestRulesLabels> |
labels
If the metric meets the specified condition in the alert rule and CloudMonitor sends an alert notification, the tag is also written to the metric and displayed in the alert notification.
|
String |
metricName
The metric name.
|
String |
namespace
The namespace of the cloud service.
|
String |
noDataPolicy
The method that is used to handle 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 |
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 alert notifications 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.
|
| 构造器和说明 |
|---|
PutResourceMetricRulesRequestRules() |
@NameInMap(value="Escalations") public PutResourceMetricRulesRequest.PutResourceMetricRulesRequestRulesEscalations escalations
@NameInMap(value="ContactGroups") public String contactGroups
The alert contact groups. The alert notifications are sent to the alert contacts in the alert contact group.
Valid values of N: 1 to 500.
> 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.
Valid values of N: 1 to 500.
@NameInMap(value="EmailSubject") public String emailSubject
The subject of the alert notification email.
Valid values of N: 1 to 500.
@NameInMap(value="Interval") public String interval
The interval at which alerts are triggered based on the alert rule.
Unit: seconds.
Valid values of N: 1 to 500.
> For information about how to query the statistical period of a metric, see [Appendix 1: Metrics](~~163515~~).
@NameInMap(value="Labels") public List<PutResourceMetricRulesRequest.PutResourceMetricRulesRequestRulesLabels> labels
If the metric meets the specified condition in the alert rule and CloudMonitor sends an alert notification, the tag is also written to the metric and displayed in the alert notification.
@NameInMap(value="MetricName") public String metricName
The metric name.
Valid values of N: 1 to 500.
For information about how to query the name of a metric, see [Appendix 1: Metrics](~~163515~~).
@NameInMap(value="Namespace") public String namespace
The namespace of the cloud service.
Valid values of N: 1 to 500.
For information about how to query the namespace of a cloud service, see [Appendix 1: Metrics](~~163515~~).
@NameInMap(value="NoDataPolicy") public String noDataPolicy
The method that is used to handle alerts when no monitoring data is found. Valid values:
* KEEP_LAST_STATE (default): No operation is performed.
* INSUFFICIENT_DATA: An alert whose content is "Insufficient data" is triggered.
* OK: The status is considered normal.
Valid values of N: 1 to 500.
@NameInMap(value="NoEffectiveInterval") public String noEffectiveInterval
The time period during which the alert rule is ineffective.
Valid values of N: 1 to 500.
@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.
Valid values of N: 1 to 500.
> For information about how to query the statistical period of a metric, see [Appendix 1: Metrics](~~163515~~).
@NameInMap(value="Resources") public String resources
The information about the resource. Example: `[{"instanceId":"i-uf6j91r34rnwawoo****"}]` or `[{"userId":"100931896542****"}]`.
Valid values of N: 1 to 500.
For more 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.
Valid values of N: 1 to 500.
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.
Valid values of N: 1 to 500.
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 alert notifications are not sent even if the trigger conditions are met.
Unit: seconds. Default value: 86400.
Valid values of N: 1 to 500.
> If an alert is not cleared after the mute period ends, CloudMonitor resends an alert notification.
@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.
Valid values of N: 1 to 500.
public static PutResourceMetricRulesRequest.PutResourceMetricRulesRequestRules build(Map<String,?> map) throws Exception
Exceptionpublic PutResourceMetricRulesRequest.PutResourceMetricRulesRequestRules setEscalations(PutResourceMetricRulesRequest.PutResourceMetricRulesRequestRulesEscalations escalations)
public PutResourceMetricRulesRequest.PutResourceMetricRulesRequestRulesEscalations getEscalations()
public PutResourceMetricRulesRequest.PutResourceMetricRulesRequestRules setContactGroups(String contactGroups)
public String getContactGroups()
public PutResourceMetricRulesRequest.PutResourceMetricRulesRequestRules setEffectiveInterval(String effectiveInterval)
public String getEffectiveInterval()
public PutResourceMetricRulesRequest.PutResourceMetricRulesRequestRules setEmailSubject(String emailSubject)
public String getEmailSubject()
public PutResourceMetricRulesRequest.PutResourceMetricRulesRequestRules setInterval(String interval)
public String getInterval()
public PutResourceMetricRulesRequest.PutResourceMetricRulesRequestRules setLabels(List<PutResourceMetricRulesRequest.PutResourceMetricRulesRequestRulesLabels> labels)
public List<PutResourceMetricRulesRequest.PutResourceMetricRulesRequestRulesLabels> getLabels()
public PutResourceMetricRulesRequest.PutResourceMetricRulesRequestRules setMetricName(String metricName)
public String getMetricName()
public PutResourceMetricRulesRequest.PutResourceMetricRulesRequestRules setNamespace(String namespace)
public String getNamespace()
public PutResourceMetricRulesRequest.PutResourceMetricRulesRequestRules setNoDataPolicy(String noDataPolicy)
public String getNoDataPolicy()
public PutResourceMetricRulesRequest.PutResourceMetricRulesRequestRules setNoEffectiveInterval(String noEffectiveInterval)
public String getNoEffectiveInterval()
public PutResourceMetricRulesRequest.PutResourceMetricRulesRequestRules setPeriod(String period)
public String getPeriod()
public PutResourceMetricRulesRequest.PutResourceMetricRulesRequestRules setResources(String resources)
public String getResources()
public PutResourceMetricRulesRequest.PutResourceMetricRulesRequestRules setRuleId(String ruleId)
public String getRuleId()
public PutResourceMetricRulesRequest.PutResourceMetricRulesRequestRules setRuleName(String ruleName)
public String getRuleName()
public PutResourceMetricRulesRequest.PutResourceMetricRulesRequestRules setSilenceTime(Integer silenceTime)
public Integer getSilenceTime()
public PutResourceMetricRulesRequest.PutResourceMetricRulesRequestRules setWebhook(String webhook)
public String getWebhook()
Copyright © 2024. All rights reserved.