public static final class DescribeAlertingMetricRuleResourcesResponseBody.Resource.Builder extends Object
public DescribeAlertingMetricRuleResourcesResponseBody.Resource.Builder comparisonOperator(String comparisonOperator)
The operator that is used to compare the metric value with the threshold. Valid values:
GreaterThanOrEqualToThreshold
public DescribeAlertingMetricRuleResourcesResponseBody.Resource.Builder expression(String expression)
The description of the alert rule.
example:This parameter indicates the content of the alert rule. If the metric value meets the alert condition, an alert is triggered.
$Average>=10
public DescribeAlertingMetricRuleResourcesResponseBody.Resource.Builder expressionList(DescribeAlertingMetricRuleResourcesResponseBody.ResourceExpressionList expressionList)
The description of the multi-metric alert rule.
public DescribeAlertingMetricRuleResourcesResponseBody.Resource.Builder expressionListJoin(String expressionListJoin)
The relationship between multiple metrics. Valid values:
&&
public DescribeAlertingMetricRuleResourcesResponseBody.Resource.Builder expressionRaw(String expressionRaw)
The trigger conditions that are created by using expressions. You can use expressions to create trigger conditions in the following scenarios:
$instanceId != \"i-io8kfvcpp7x5****\" ``&&`` $Average > 50, no alert is triggered when the average metric value of the i-io8kfvcpp7x5**** instance exceeds 50.$Average > ($instanceId == \"i-io8kfvcpp7x5****\"? 80: 50), an alert is triggered when the average metric value of the i-io8kfvcpp7x5**** instance exceeds 80 or the average metric value of other instances exceeds 50.count($Average > 20) > 3, an alert is triggered only when the average metric value of more than three instances exceeds 20.$Average > ($instanceId == "i-io8kfvcpp7x5****"? 80: 50)
public DescribeAlertingMetricRuleResourcesResponseBody.Resource.Builder level(Integer level)
The severity level and notification methods of the alert. Valid values:
3
public DescribeAlertingMetricRuleResourcesResponseBody.Resource.Builder preCondition(String preCondition)
The operator that is used to compare the metric value with the threshold. Valid values:
>==<=><!==
public DescribeAlertingMetricRuleResourcesResponseBody.Resource.Builder tag(String tag)
This parameter is deprecated.
example:mns
public DescribeAlertingMetricRuleResourcesResponseBody.Resource.Builder threshold(String threshold)
The alert threshold.
example:10
public DescribeAlertingMetricRuleResourcesResponseBody.Resource.Builder times(Integer times)
The consecutive number of times for which the metric value meets the alert condition before an alert is triggered.
example:1
public DescribeAlertingMetricRuleResourcesResponseBody.Resource build()
Copyright © 2026. All rights reserved.