public static class CreateMetricRuleTemplateRequest.CreateMetricRuleTemplateRequestAlertTemplates
extends com.aliyun.tea.TeaModel
| 限定符和类型 | 字段和说明 |
|---|---|
String |
category
The abbreviation of the cloud service name.
|
CreateMetricRuleTemplateRequest.CreateMetricRuleTemplateRequestAlertTemplatesEscalations |
escalations |
String |
metricName
The metric name.
|
String |
namespace
The namespace of the cloud service.
|
Integer |
period
The aggregation period of monitoring data.
|
String |
ruleName
The name of the alert rule.
|
String |
selector
The dimension of the alert.
|
String |
webhook
The callback URL.
|
| 构造器和说明 |
|---|
CreateMetricRuleTemplateRequestAlertTemplates() |
@NameInMap(value="Escalations") public CreateMetricRuleTemplateRequest.CreateMetricRuleTemplateRequestAlertTemplatesEscalations escalations
@NameInMap(value="Category") public String category
The abbreviation of the cloud service name.
Valid values of N: 1 to 200.
For more information about how to obtain the abbreviation of a cloud service name, see metricCategory in the response parameter Labels of the DescribeProjectMeta operation.
This parameter is required.
example:ecs
@NameInMap(value="MetricName") public String metricName
The metric name.
Valid values of N: 1 to 200.
For information about how to obtain the name of a metric, see DescribeMetricMetaList or Metrics.
This parameter is required.
example:cpu_total
@NameInMap(value="Namespace") public String namespace
The namespace of the cloud service.
Valid values of N: 1 to 200.
For information about how to obtain the namespace of a cloud service, see DescribeMetricMetaList or Appendix 1: Metrics.
This parameter is required.
example:acs_ecs_dashboard
@NameInMap(value="Period") public Integer period
The aggregation period of monitoring data. Unit: seconds.
The default value is the minimum aggregation period. Generally, you do not need to specify the minimum aggregation period.
Valid values of N: 1 to 200.
example:60
@NameInMap(value="RuleName") public String ruleName
The name of the alert rule.
Valid values of N: 1 to 200.
This parameter is required.
example:ECS_Rule1
@NameInMap(value="Selector") public String selector
The dimension of the alert. It is an extended field.
Valid values of N: 1 to 200.
For example, an alert template is applied to an application group, this parameter is set to {"disk":"/"}, and the MetricName parameter is set to DiskUtilization. In this case, the generated alert rule is applied to the root disk partition ("/") of all instances in the application group to which the alert template is applied.
example:For more information about the values of extended fields, see DescribeMetricRuleTemplateAttribute.
{"disk":"/"}
@NameInMap(value="Webhook") public String webhook
The callback URL.
Valid values of N: 1 to 200.
The callback URL must be accessible over the Internet. CloudMonitor pushes an alert notification to the specified callback URL by sending an HTTP POST request. Only the HTTP protocol is supported.
example:public CreateMetricRuleTemplateRequestAlertTemplates()
public static CreateMetricRuleTemplateRequest.CreateMetricRuleTemplateRequestAlertTemplates build(Map<String,?> map) throws Exception
Exceptionpublic CreateMetricRuleTemplateRequest.CreateMetricRuleTemplateRequestAlertTemplates setEscalations(CreateMetricRuleTemplateRequest.CreateMetricRuleTemplateRequestAlertTemplatesEscalations escalations)
public CreateMetricRuleTemplateRequest.CreateMetricRuleTemplateRequestAlertTemplatesEscalations getEscalations()
public CreateMetricRuleTemplateRequest.CreateMetricRuleTemplateRequestAlertTemplates setCategory(String category)
public String getCategory()
public CreateMetricRuleTemplateRequest.CreateMetricRuleTemplateRequestAlertTemplates setMetricName(String metricName)
public String getMetricName()
public CreateMetricRuleTemplateRequest.CreateMetricRuleTemplateRequestAlertTemplates setNamespace(String namespace)
public String getNamespace()
public CreateMetricRuleTemplateRequest.CreateMetricRuleTemplateRequestAlertTemplates setPeriod(Integer period)
public Integer getPeriod()
public CreateMetricRuleTemplateRequest.CreateMetricRuleTemplateRequestAlertTemplates setRuleName(String ruleName)
public String getRuleName()
public CreateMetricRuleTemplateRequest.CreateMetricRuleTemplateRequestAlertTemplates setSelector(String selector)
public String getSelector()
public CreateMetricRuleTemplateRequest.CreateMetricRuleTemplateRequestAlertTemplates setWebhook(String webhook)
public String getWebhook()
Copyright © 2026. All rights reserved.