查詢MongoDB分區叢集執行個體的串連資訊。
介面說明
該介面僅支援分區叢集執行個體。
調試
您可以在OpenAPI Explorer中直接運行該介面,免去您計算簽名的困擾。運行成功後,OpenAPI Explorer可以自動產生SDK程式碼範例。
調試
授權資訊
|
操作 |
存取層級 |
資源類型 |
條件關鍵字 |
關聯操作 |
|
dds:DescribeShardingNetworkAddress |
get |
*Instance
|
無 | 無 |
請求參數
|
名稱 |
類型 |
必填 |
描述 |
樣本值 |
| DBInstanceId |
string |
是 |
執行個體 ID。 |
dds-bpxxxxxxxx |
| NodeId |
string |
否 |
分區叢集執行個體中 Mongos 節點 ID、Shard 節點 ID 或 ConfigServer 節點 ID。 說明
您可以調用 DescribeDBInstanceAttribute 介面查詢 Mongos/Shard/ConfigServer 節點 ID。 |
d-bpxxxxxxxx |
| NetworkType |
string |
否 |
網路類型,取值:
|
VPC |
返回參數
|
名稱 |
類型 |
描述 |
樣本值 |
|
object |
|||
| CompatibleConnections |
object |
||
| CompatibleConnection |
array<object> |
DynamoDB 協議類型執行個體的串連地址資訊列表。 |
|
|
object |
|||
| VswitchId |
string |
專用網路中交換器 ID。 說明
當網路類型為 VPC 時返回該參數。 |
vsw-bpxxxxxxxx |
| ExpiredTime |
string |
保留的傳統網路地址剩餘時間長度,單位為秒。 |
2591963 |
| NetworkType |
string |
網路類型。
|
VPC |
| Port |
string |
串連連接埠。 |
3717 |
| NetworkAddress |
string |
串連地址。 |
dds-bpxxxxxxxxxxxxxx.mongodb.rds.aliyuncs.com |
| VPCId |
string |
專用網路 ID。 說明
當網路類型為 VPC 時返回該參數。 |
vpc-bpxxxxxxxx |
| IPAddress |
string |
IP 位址。 |
10.140.xxx.xx |
| RequestId |
string |
請求 ID。 |
18D8AAFD-6BEB-420F-8164-810CB0C0AA39 |
| NetworkAddresses |
object |
||
| NetworkAddress |
array<object> |
MongoDB 協議類型執行個體的串連地址資訊列表。 |
|
|
object |
|||
| NodeType |
string |
節點類型,傳回值為
|
mongos |
| VswitchId |
string |
專用網路中交換器 ID。 說明
當網路類型為 VPC 時返回該參數。 |
vsw-bpxxxxxxxx |
| ExpiredTime |
string |
保留的傳統網路地址剩餘時間長度,單位為秒。 |
2591963 |
| NetworkType |
string |
網路類型。
|
VPC |
| Role |
string |
節點角色,傳回值:
|
Primary |
| Port |
string |
串連連接埠。 |
3717 |
| VPCId |
string |
專用網路 ID。 說明
當網路類型為 VPC 時返回該參數。 |
vpc-bpxxxxxxxx |
| NetworkAddress |
string |
串連地址(字串)。 |
s-bpxxxxxxxx.mongodb.rds.aliyuncs.com |
| NodeId |
string |
Mongos 節點 ID。 |
s-bpxxxxxxxx |
| IPAddress |
string |
IP 位址。 |
10.140.xxx.xx |
| ConnectionType |
string |
公網地址類型,可選值:
|
SRV |
| TxtRecord |
string |
TXT 記錄,用來儲存 MongoDB 相關的元資訊,如版本資訊、配置參數等,可結合 SRV 記錄等其他技術實現複雜的服務發現和配置傳遞等功能。 |
mongo.example.com. IN TXT "config=replicaSet=myReplicaSet" |
| ConnectionStringSuffix |
string |
串連串網域名稱尾碼。 |
.mongodb.rds.aliyuncs.com |
樣本
正常返回樣本
JSON格式
{
"CompatibleConnections": {
"CompatibleConnection": [
{
"VswitchId": "vsw-bpxxxxxxxx",
"ExpiredTime": "2591963",
"NetworkType": "VPC",
"Port": "3717",
"NetworkAddress": "dds-bpxxxxxxxxxxxxxx.mongodb.rds.aliyuncs.com",
"VPCId": "vpc-bpxxxxxxxx",
"IPAddress": "10.140.xxx.xx"
}
]
},
"RequestId": "18D8AAFD-6BEB-420F-8164-810CB0C0AA39",
"NetworkAddresses": {
"NetworkAddress": [
{
"NodeType": "mongos",
"VswitchId": "vsw-bpxxxxxxxx",
"ExpiredTime": "2591963",
"NetworkType": "VPC",
"Role": "Primary",
"Port": "3717",
"VPCId": "vpc-bpxxxxxxxx",
"NetworkAddress": "s-bpxxxxxxxx.mongodb.rds.aliyuncs.com",
"NodeId": "s-bpxxxxxxxx",
"IPAddress": "10.140.xxx.xx",
"ConnectionType": "SRV",
"TxtRecord": "mongo.example.com. IN TXT \"config=replicaSet=myReplicaSet\""
}
]
},
"ConnectionStringSuffix": ".mongodb.rds.aliyuncs.com"
}
錯誤碼
訪問錯誤中心查看更多錯誤碼。
變更歷史
更多資訊,參考變更詳情。