ALIYUN::ResourceManager::SavedQuery类型用于创建自定义查询模板。
语法
{
"Type": "ALIYUN::ResourceManager::SavedQuery",
"Properties": {
"Expression": String,
"SavedQueryName": String,
"Description": String
}
}
属性
|
属性名称 |
类型 |
必须 |
允许更新 |
描述 |
约束 |
|
Expression |
String |
是 |
是 |
模板的表达式。 |
无 |
|
SavedQueryName |
String |
是 |
是 |
模板的名称。 |
* 名称长度必须为1到64个字符。 * 名称可以包含字母、数字、下划线(_)和连字符(-)。 * 模板名称必须唯一。 |
|
Description |
String |
否 |
是 |
模板的描述。 |
描述长度必须为1到256个字符。 |
返回值
Fn::GetAtt
-
Description:模板的描述。
-
Expression:模板的查询表达式。
-
CreateTime:模板的创建时间。
-
UpdateTime:模板的更新时间。
-
SavedQueryId:模板的ID。
-
SavedQueryName:模板的名称。
示例
ROSTemplateFormatVersion: '2015-09-01'
Parameters:
SavedQueryName:
Type: String
Description:
en: |-
The name of the template.
* The name must be 1 to 64 characters in length.
* The name can contain letters, digits, underscores (_), and hyphens (-).
* The template name must be unique.
MinLength: 1
MaxLength: 64
Required: true
Expression:
Type: String
Description:
en: The expression of the template.
Required: true
Description:
Type: String
Description:
en: The description of the template. The description must be 1 to 256 characters in length.
AssociationProperty: TextArea
MinLength: 1
MaxLength: 256
Default: Null
Required: false
Resources:
ExtensionResource:
Type: ALIYUN::ResourceManager::SavedQuery
Properties:
SavedQueryName:
Ref: SavedQueryName
Expression:
Ref: Expression
Description:
Ref: Description
Outputs:
UpdateTime:
Value:
Fn::GetAtt:
- ExtensionResource
- UpdateTime
Description: Update time of the template.
Description:
Value:
Fn::GetAtt:
- ExtensionResource
- Description
Description: 'The description of the template. '
SavedQueryName:
Value:
Fn::GetAtt:
- ExtensionResource
- SavedQueryName
Description: The name of the template.
SavedQueryId:
Value:
Fn::GetAtt:
- ExtensionResource
- SavedQueryId
Description: The id of the template.
Expression:
Value:
Fn::GetAtt:
- ExtensionResource
- Expression
Description: Query Expression of the template.
CreateTime:
Value:
Fn::GetAtt:
- ExtensionResource
- CreateTime
Description: The creation time of the template.
{
"ROSTemplateFormatVersion": "2015-09-01",
"Parameters": {
"SavedQueryName": {
"Type": "String",
"Description": {
"en": "The name of the template.\n* The name must be 1 to 64 characters in length.\n* The name can contain letters, digits, underscores (_), and hyphens (-).\n* The template name must be unique."
},
"MinLength": 1,
"MaxLength": 64,
"Required": true
},
"Expression": {
"Type": "String",
"Description": {
"en": "The expression of the template."
},
"Required": true
},
"Description": {
"Type": "String",
"Description": {
"en": "The description of the template. The description must be 1 to 256 characters in length."
},
"AssociationProperty": "TextArea",
"MinLength": 1,
"MaxLength": 256,
"Default": null,
"Required": false
}
},
"Resources": {
"ExtensionResource": {
"Type": "ALIYUN::ResourceManager::SavedQuery",
"Properties": {
"SavedQueryName": {
"Ref": "SavedQueryName"
},
"Expression": {
"Ref": "Expression"
},
"Description": {
"Ref": "Description"
}
}
}
},
"Outputs": {
"UpdateTime": {
"Value": {
"Fn::GetAtt": [
"ExtensionResource",
"UpdateTime"
]
},
"Description": "Update time of the template."
},
"Description": {
"Value": {
"Fn::GetAtt": [
"ExtensionResource",
"Description"
]
},
"Description": "The description of the template. "
},
"SavedQueryName": {
"Value": {
"Fn::GetAtt": [
"ExtensionResource",
"SavedQueryName"
]
},
"Description": "The name of the template."
},
"SavedQueryId": {
"Value": {
"Fn::GetAtt": [
"ExtensionResource",
"SavedQueryId"
]
},
"Description": "The id of the template."
},
"Expression": {
"Value": {
"Fn::GetAtt": [
"ExtensionResource",
"Expression"
]
},
"Description": "Query Expression of the template."
},
"CreateTime": {
"Value": {
"Fn::GetAtt": [
"ExtensionResource",
"CreateTime"
]
},
"Description": "The creation time of the template."
}
}
}该文章对您有帮助吗?