ALIYUN::MONGODB::ShardingNetworkPrivateAddress类型用于为云数据库分片集群实例节点申请内网连接地址。
语法
{
"Type": "ALIYUN::MONGODB::ShardingNetworkPrivateAddress",
"Properties": {
"DBInstanceId": String,
"NodeId": String,
"AccountPassword": String,
"AccountName": String,
"ZoneId": String
}
}
属性
|
属性名称 |
类型 |
必须 |
允许更新 |
描述 |
约束 |
|
DBInstanceId |
String |
是 |
否 |
分片集群实例ID。 |
无 |
|
NodeId |
String |
是 |
否 |
分片集群实例中的Mongos节点、Shard节点或ConfigServer节点的ID。 |
无 |
|
AccountName |
String |
否 |
否 |
账号名称。 |
|
|
AccountPassword |
String |
否 |
否 |
账号密码。 |
密码由大写字母、小写字母、数字和特殊字符中的至少三种组成,特殊字符为'! #$%^& *()_+-=' - 密码长度为8-32位。 |
|
ZoneId |
String |
否 |
否 |
实例所属可用区ID。 |
无 |
返回值
Fn::GetAtt
-
CompatibleConnections:DynamoDB协议实例的连接地址列表。
-
NetworkAddresses:MongoDB协议类型实例的连接地址列表。
示例
ROSTemplateFormatVersion: '2015-09-01'
Parameters:
NodeId:
Type: String
Description:
en: |-
The ID of the Mongos node, Shard node, or ConfigServer node in the sharded cluster instance.
> You can call the [DescribeDBInstanceAttribute] interface to query the Mongos, Shard, and ConfigServer node ID.
Required: true
ZoneId:
Type: String
Description:
en: |-
The ID of the zone to which the instance belongs.
> You can call the [describeddinstanceattribute] operation to query the zone ID of an instance.
AssociationProperty: ZoneId
Default: Null
Required: false
DBInstanceId:
Type: String
Description:
en: The ID of the Shard cluster instance.
Required: true
AccountPassword:
Type: String
Description:
en: |-
Account password.
- The password consists of at least three of uppercase letters, lowercase letters, numbers, and special characters. The special character is '! #$%^& *()_+-='
- The password length is 8-32 bits.
Default: Null
Required: false
AccountName:
Type: String
Description:
en: |-
Account name.
>- starts with a lowercase letter, has 4 to 16 digits in length, and consists of lowercase letters, numbers, or underscores.
- Only when you apply for the Shard/ConfigServer address for the first time, you need to set the account name and password. That is, all Shard nodes and ConfigServer nodes will use the account and password set when applying for the address for the first time.
- The permissions of this account are fixed to read-only.
Default: Null
Required: false
Resources:
ExtensionResource:
Type: ALIYUN::MONGODB::ShardingNetworkPrivateAddress
Properties:
NodeId:
Ref: NodeId
ZoneId:
Ref: ZoneId
DBInstanceId:
Ref: DBInstanceId
AccountPassword:
Ref: AccountPassword
AccountName:
Ref: AccountName
Outputs:
NetworkAddresses:
Value:
Fn::GetAtt:
- ExtensionResource
- NetworkAddresses
Description: A list of connection addresses of an instance of the MongoDB protocol type.
CompatibleConnections:
Value:
Fn::GetAtt:
- ExtensionResource
- CompatibleConnections
Description: The list of connection addresses of the DynamoDB protocol instance.
{
"ROSTemplateFormatVersion": "2015-09-01",
"Parameters": {
"NodeId": {
"Type": "String",
"Description": {
"en": "The ID of the Mongos node, Shard node, or ConfigServer node in the sharded cluster instance.\n> You can call the [DescribeDBInstanceAttribute] interface to query the Mongos, Shard, and ConfigServer node ID."
},
"Required": true
},
"ZoneId": {
"Type": "String",
"Description": {
"en": "The ID of the zone to which the instance belongs.\n> You can call the [describeddinstanceattribute] operation to query the zone ID of an instance."
},
"AssociationProperty": "ZoneId",
"Default": null,
"Required": false
},
"DBInstanceId": {
"Type": "String",
"Description": {
"en": "The ID of the Shard cluster instance."
},
"Required": true
},
"AccountPassword": {
"Type": "String",
"Description": {
"en": "Account password.\n- The password consists of at least three of uppercase letters, lowercase letters, numbers, and special characters. The special character is '! #$%^& *()_+-='\n- The password length is 8-32 bits."
},
"Default": null,
"Required": false
},
"AccountName": {
"Type": "String",
"Description": {
"en": "Account name.\n>- starts with a lowercase letter, has 4 to 16 digits in length, and consists of lowercase letters, numbers, or underscores.\n- Only when you apply for the Shard/ConfigServer address for the first time, you need to set the account name and password. That is, all Shard nodes and ConfigServer nodes will use the account and password set when applying for the address for the first time.\n- The permissions of this account are fixed to read-only."
},
"Default": null,
"Required": false
}
},
"Resources": {
"ExtensionResource": {
"Type": "ALIYUN::MONGODB::ShardingNetworkPrivateAddress",
"Properties": {
"NodeId": {
"Ref": "NodeId"
},
"ZoneId": {
"Ref": "ZoneId"
},
"DBInstanceId": {
"Ref": "DBInstanceId"
},
"AccountPassword": {
"Ref": "AccountPassword"
},
"AccountName": {
"Ref": "AccountName"
}
}
}
},
"Outputs": {
"NetworkAddresses": {
"Value": {
"Fn::GetAtt": [
"ExtensionResource",
"NetworkAddresses"
]
},
"Description": "A list of connection addresses of an instance of the MongoDB protocol type."
},
"CompatibleConnections": {
"Value": {
"Fn::GetAtt": [
"ExtensionResource",
"CompatibleConnections"
]
},
"Description": "The list of connection addresses of the DynamoDB protocol instance."
}
}
}该文章对您有帮助吗?