ALIYUN::ARMS::DeliverTask类型用于创建投递任务。
语法
{
"Type": "ALIYUN::ARMS::DeliverTask",
"Properties": {
"TargetList": List,
"TaskName": String,
"DataSourceName": String,
"DataSourceId": String,
"ExternalLabel": String,
"FilterType": Boolean,
"FilterList": String,
"TaskDescription": String
}
}
属性
属性名称 | 类型 | 必须 | 允许更新 | 描述 | 约束 |
TargetList | List | 是 | 是 | 投递目标列表。 | 详情参考TargetList属性。 |
TaskName | String | 是 | 否 | 投递任务名称。 | 无 |
DataSourceName | String | 否 | 是 | 数据源的名称。 | 无 |
DataSourceId | String | 否 | 是 | 数据源的ID。 | 无 |
ExternalLabel | String | 否 | 是 | 任务的外部标签。 | 无 |
FilterType | Boolean | 否 | 否 | 数据过滤是否采用白名单机制。 | 默认值:true。 |
FilterList | String | 否 | 是 | 设置用于过滤的指标。 | 支持正则表达式、多个换行符以及多种条件以实现精准传递。 |
TaskDescription | String | 否 | 否 | 投递任务描述。 | 无 |
TargetList语法
"TargetList": [
{
"TargetParam": String,
"TargetType": String,
"FaultTolerantPolicy": String,
"TargetName": String,
"RetryPolicy": String
}
]
TargetList属性
属性名称 | 类型 | 必须 | 允许更新 | 描述 | 约束 |
TargetType | String | 是 | 是 | 投递目标的类型。 | 无 |
FaultTolerantPolicy | String | 否 | 是 | 投递目标的容错策略。 | 取值:
|
RetryPolicy | String | 否 | 是 | 投递目标的重试策略。 | 取值:
|
TargetParam | String | 否 | 是 | 投递目标的参数。 | 无 |
TargetName | String | 否 | 是 | 投递目标的名称。 | 无 |
返回值
Fn::GetAtt
TaskId:投递任务ID。
示例
ROSTemplateFormatVersion: '2015-09-01'
Parameters:
TargetList:
AssociationPropertyMetadata:
Parameters:
TargetParam:
Type: String
Description:
en: The parameter of the target.
Required: false
TargetType:
Type: String
Description:
en: The type of the target.
Required: true
FaultTolerantPolicy:
Type: String
Description:
en: |-
The fault tolerant policy of the target. Valid values:
- ALL (default): Exception tolerance is allowed. When an exception occurs, the execution will not be blocked, and the message will be delivered to the dead message queue or dropped directly according to the configuration after exceeding the retry policy.
- NONE: Fault tolerance is not allowed and execution is blocked when an exception occurs and exceeds the retry policy configuration.
AllowedValues:
- ALL
- NONE
Required: false
Default: ALL
TargetName:
Type: String
Description:
en: The name of the target.
Required: false
RetryPolicy:
Type: String
Description:
en: |-
The retry policy of the target. Valid values:
- BACKOFF_RETRY: retry three times, with a random interval between 10 and 20 seconds
- EXPONENTIAL_DECAY_RETRY (default): retry 176 times, each retry interval exponentially increased to 512 seconds, total retry time is 1 day; The interval for each retry is: 1,2,4,8,... 512 seconds.
AllowedValues:
- BACKOFF_RETRY
- EXPONENTIAL_DECAY_RETRY
Required: false
Default: EXPONENTIAL_DECAY_RETRY
AssociationProperty: List[Parameters]
Type: Json
Description:
en: The list of the target.
Required: true
TaskName:
Type: String
Description:
en: The name of the task.
AllowedPattern: '[a-zA-Z0-9-]{1,64}'
Required: true
Resources:
DeliverTask:
Type: ALIYUN::ARMS::DeliverTask
Properties:
TargetList:
Ref: TargetList
TaskName:
Ref: TaskName
Outputs:
TaskId:
Description: The ID of the task.
Value:
Fn::GetAtt:
- DeliverTask
- TaskId
{
"ROSTemplateFormatVersion": "2015-09-01",
"Parameters": {
"TargetList": {
"AssociationPropertyMetadata": {
"Parameters": {
"TargetParam": {
"Type": "String",
"Description": {
"en": "The parameter of the target."
},
"Required": false
},
"TargetType": {
"Type": "String",
"Description": {
"en": "The type of the target."
},
"Required": true
},
"FaultTolerantPolicy": {
"Type": "String",
"Description": {
"en": "The fault tolerant policy of the target. Valid values:\n- ALL (default): Exception tolerance is allowed. When an exception occurs, the execution will not be blocked, and the message will be delivered to the dead message queue or dropped directly according to the configuration after exceeding the retry policy.\n- NONE: Fault tolerance is not allowed and execution is blocked when an exception occurs and exceeds the retry policy configuration."
},
"AllowedValues": [
"ALL",
"NONE"
],
"Required": false,
"Default": "ALL"
},
"TargetName": {
"Type": "String",
"Description": {
"en": "The name of the target."
},
"Required": false
},
"RetryPolicy": {
"Type": "String",
"Description": {
"en": "The retry policy of the target. Valid values:\n- BACKOFF_RETRY: retry three times, with a random interval between 10 and 20 seconds\n- EXPONENTIAL_DECAY_RETRY (default): retry 176 times, each retry interval exponentially increased to 512 seconds, total retry time is 1 day; The interval for each retry is: 1,2,4,8,... 512 seconds."
},
"AllowedValues": [
"BACKOFF_RETRY",
"EXPONENTIAL_DECAY_RETRY"
],
"Required": false,
"Default": "EXPONENTIAL_DECAY_RETRY"
}
}
},
"AssociationProperty": "List[Parameters]",
"Type": "Json",
"Description": {
"en": "The list of the target."
},
"Required": true
},
"TaskName": {
"Type": "String",
"Description": {
"en": "The name of the task."
},
"AllowedPattern": "[a-zA-Z0-9-]{1,64}",
"Required": true
}
},
"Resources": {
"DeliverTask": {
"Type": "ALIYUN::ARMS::DeliverTask",
"Properties": {
"TargetList": {
"Ref": "TargetList"
},
"TaskName": {
"Ref": "TaskName"
}
}
}
},
"Outputs": {
"TaskId": {
"Description": "The ID of the task.",
"Value": {
"Fn::GetAtt": [
"DeliverTask",
"TaskId"
]
}
}
}
}
文档内容是否对您有帮助?