CreateDIAlarmRule
Create alert rules for data integration tasks in DataWorks MCP Server. Configure thresholds, triggers, and notifications for metrics like task delays, failures, or resource usage to ensure timely issue detection and response.
Instructions
创建数据集成同步任务告警规则 *This Tool has a 'MCP Resource',please request CreateDIAlarmRule(MCP Resource) to get more examples for using this tool.
Input Schema
Name | Required | Description | Default |
---|---|---|---|
ClientToken | No | 幂等参数 | |
DIJobId | No | 任务ID,是告警规则关联的任务ID | |
Description | No | 描述 | |
Enabled | No | 告警规则是否启用,默认不开启 | |
MetricType | Yes | 告警指标类型,可选的枚举值:- Heartbeat(任务状态报警)- FailoverCount(failover次数报警)- Delay(任务延迟报警)- DdlReport(DDL通知)- ResourceUtilization(资源组使用率) | |
Name | Yes | 告警规则名称 | |
NotificationSettings | Yes | 告警通知设置 | |
TriggerConditions | Yes | 告警触发条件列表,支持多条件 |
Input Schema (JSON Schema)
{
"$schema": "http://json-schema.org/draft-07/schema#",
"additionalProperties": false,
"properties": {
"ClientToken": {
"description": "幂等参数",
"type": "string"
},
"DIJobId": {
"description": "任务ID,是告警规则关联的任务ID"
},
"Description": {
"description": "描述",
"type": "string"
},
"Enabled": {
"description": "告警规则是否启用,默认不开启",
"type": "boolean"
},
"MetricType": {
"description": "告警指标类型,可选的枚举值:- Heartbeat(任务状态报警)- FailoverCount(failover次数报警)- Delay(任务延迟报警)- DdlReport(DDL通知)- ResourceUtilization(资源组使用率)",
"type": "string"
},
"Name": {
"description": "告警规则名称",
"type": "string"
},
"NotificationSettings": {
"additionalProperties": false,
"description": "告警通知设置",
"properties": {
"InhibitionInterval": {
"description": "该字段已废弃,请使用MuteInterval进行配置"
},
"MuteInterval": {
"description": "告警抑制间隔时长,单位分钟,默认5分钟"
},
"NotificationChannels": {
"description": "告警通知渠道",
"items": {
"additionalProperties": false,
"properties": {
"Channels": {
"description": "通道,可选的枚举值:- Mail(邮件)- Phone(电话)- Sms(短信)- Ding(钉钉)",
"items": {
"type": "string"
},
"type": "array"
},
"Severity": {
"description": "严重程度,可选的枚举值:- Warning- Critical",
"type": "string"
}
},
"type": "object"
},
"type": "array"
},
"NotificationReceivers": {
"description": "告警通知接收方",
"items": {
"additionalProperties": false,
"properties": {
"ReceiverType": {
"description": "接收方类型,取值范围:AliyunUid/DingToken/FeishuToken/WebHookUrl",
"type": "string"
},
"ReceiverValues": {
"description": "接收方取值。-当接收方类型为阿里云ID时,接收方取值为具体阿里云用户ID。-当接收方类型为钉钉token时,接收方取值为具体钉钉token值",
"items": {
"type": "string"
},
"type": "array"
}
},
"type": "object"
},
"type": "array"
}
},
"type": "object"
},
"TriggerConditions": {
"description": "告警触发条件列表,支持多条件",
"items": {
"additionalProperties": false,
"properties": {
"DdlReportTags": {
"description": "该字段已废弃,请使用DdlTypes字段",
"items": {
"type": "string"
},
"type": "array"
},
"DdlTypes": {
"description": "在DDL通知的时候才生效,需要生效的DDL列表",
"items": {
"type": "string"
},
"type": "array"
},
"Duration": {
"description": "告警计算时间区间,单位分钟"
},
"Severity": {
"description": "严重程度,可选的枚举值:- Warning- Critical",
"type": "string"
},
"Threshold": {
"description": "告警阈值。- 任务状态报警:无需填写阈值。- failover次数报警:阈值为failover次数。- 任务延迟报警:阈值为延迟时长,单位秒"
}
},
"type": "object"
},
"type": "array"
}
},
"required": [
"MetricType",
"Name",
"TriggerConditions",
"NotificationSettings"
],
"type": "object"
}