DATASOURCE::PolarDBX::Account类型用于获取PolarDB-X账号信息。
语法
{
"Type": "DATASOURCE::PolarDBX::Account",
"Properties": {
"DBInstanceId": String,
"PolarDBXAccountName": String,
"RefreshOptions": String
}
}
属性
属性名称 | 类型 | 必须 | 允许更新 | 描述 | 约束 |
DBInstanceId | String | 是 | 是 | PolarDB-X实例ID。 | 无 |
PolarDBXAccountName | String | 是 | 是 | PolarDB-X账户名称。 | 无 |
RefreshOptions | String | 否 | 是 | 当资源栈更新时,数据源资源的刷新策略。 | 有效值:
|
返回值
Fn::GetAtt
PolarDBXAccountName:PolarDB-X账户名称。
AccountDescription:PolarDB-X账户描述。
DBInstanceId:PolarDB-X实例ID。
CreateTime:账户创建时间。
AccountType:账号类型。
示例
ROSTemplateFormatVersion: '2015-09-01'
Parameters:
PolarDBXAccountName:
Type: String
Description:
en: The username of the account that you want to query. If you want to query information about a specific account, you must specify this parameter.
Required: true
DBInstanceId:
Type: String
Description:
en: The ID of the PolarDB-X 2.0 instance.
Required: true
Resources:
ExtensionDataSource:
Type: DATASOURCE::PolarDBX::Account
Properties:
PolarDBXAccountName:
Ref: PolarDBXAccountName
DBInstanceId:
Ref: DBInstanceId
Outputs:
PolarDBXAccountName:
Description: The username of the account.
Value:
Fn::GetAtt:
- ExtensionDataSource
- PolarDBXAccountName
AccountDescription:
Description: The description of the account.
Value:
Fn::GetAtt:
- ExtensionDataSource
- AccountDescription
DBInstanceId:
Description: The ID of the PolarDB-X 2.0 instance.
Value:
Fn::GetAtt:
- ExtensionDataSource
- DBInstanceId
CreateTime:
Description: The point in time when the account was created.
Value:
Fn::GetAtt:
- ExtensionDataSource
- CreateTime
AccountType:
Description: The type of the account.
Value:
Fn::GetAtt:
- ExtensionDataSource
- AccountType
{
"ROSTemplateFormatVersion": "2015-09-01",
"Parameters": {
"PolarDBXAccountName": {
"Type": "String",
"Description": {
"en": "The username of the account that you want to query. If you want to query information about a specific account, you must specify this parameter."
},
"Required": true
},
"DBInstanceId": {
"Type": "String",
"Description": {
"en": "The ID of the PolarDB-X 2.0 instance."
},
"Required": true
}
},
"Resources": {
"ExtensionDataSource": {
"Type": "DATASOURCE::PolarDBX::Account",
"Properties": {
"PolarDBXAccountName": {
"Ref": "PolarDBXAccountName"
},
"DBInstanceId": {
"Ref": "DBInstanceId"
}
}
}
},
"Outputs": {
"PolarDBXAccountName": {
"Description": "The username of the account.",
"Value": {
"Fn::GetAtt": [
"ExtensionDataSource",
"PolarDBXAccountName"
]
}
},
"AccountDescription": {
"Description": "The description of the account.",
"Value": {
"Fn::GetAtt": [
"ExtensionDataSource",
"AccountDescription"
]
}
},
"DBInstanceId": {
"Description": "The ID of the PolarDB-X 2.0 instance.",
"Value": {
"Fn::GetAtt": [
"ExtensionDataSource",
"DBInstanceId"
]
}
},
"CreateTime": {
"Description": "The point in time when the account was created.",
"Value": {
"Fn::GetAtt": [
"ExtensionDataSource",
"CreateTime"
]
}
},
"AccountType": {
"Description": "The type of the account.",
"Value": {
"Fn::GetAtt": [
"ExtensionDataSource",
"AccountType"
]
}
}
}
}
该文章对您有帮助吗?