Queries the topologies of a logical database and its physical database shards.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
dms:GetDBTopology |
get |
*All Resource
|
None | None |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| LogicDbId |
integer |
Yes |
The ID of the logical database. You can call the ListLogicDatabases or SearchDatabase operation to obtain the logical database ID. |
134325 |
| Tid |
integer |
No |
The ID of the tenant. Note
To view the tenant ID, move the pointer over the profile picture in the upper-right corner of the Data Management (DMS) console. For more information, see Manage DMS tenants. |
43215 |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
Schema of Response |
||
| RequestId |
string |
The ID of the request. |
C5B8E84B-42B6-4374-AD5A-6264E1753378 |
| Success |
boolean |
Indicates whether the request is successful. Valid values:
|
true |
| ErrorMessage |
string |
The error message returned if the request failed. |
UnknownError |
| ErrorCode |
string |
The error code. |
UnknownError |
| DBTopology |
object |
The topology of the data table. |
|
| LogicDbId |
integer |
The ID of the logical database. |
1234 |
| LogicDbName |
string |
The name of the logical database. |
logic_db_test |
| SearchName |
string |
The name of the saved search. |
logic_db_test |
| Alias |
string |
The alias of the access point. |
logic_db_test |
| DbType |
string |
The type of the database engine. |
polardb |
| EnvType |
string |
The type of the environment in which the database instance is deployed. Valid values:
|
dev |
| DBTopologyInfoList |
array<object> |
The topology information about the physical database shards. |
|
|
object |
|||
| DbId |
integer |
The ID of the database for which the schema design is executed. |
423532 |
| SchemaName |
string |
The name of the logical database. Note
If the database is a PostgreSQL database, the value of this parameter is the name of the database schema. |
db_test@rm-xxx:3306 |
| CatalogName |
string |
The name of the catalog to which the database belongs. Note
If the database is a PostgreSQL database, the value of this parameter is the name of the database. |
def |
| SearchName |
string |
The name of the saved search. |
db_test |
| DbType |
string |
The type of the database engine. |
polardb |
| EnvType |
string |
The type of the environment to which the database belongs. Valid values:
|
dev |
| InstanceId |
integer |
The ID of the instance. You can call the ListInstances operation to query this value. This is the DMS instance ID, not the RDS instance ID. |
4325325 |
| RegionId |
string |
The ID of the region in which the instance resides. |
cn-hangzhou |
| InstanceResourceId |
string |
The resource ID of the instance. |
rm-xxx |
| InstanceSource |
string |
The source of the database instance. Valid values:
|
RDS |
Examples
Success response
JSON format
{
"RequestId": "C5B8E84B-42B6-4374-AD5A-6264E1753378",
"Success": true,
"ErrorMessage": "UnknownError",
"ErrorCode": "UnknownError",
"DBTopology": {
"LogicDbId": 1234,
"LogicDbName": "logic_db_test",
"SearchName": "logic_db_test",
"Alias": "logic_db_test",
"DbType": "polardb",
"EnvType": "dev",
"DBTopologyInfoList": [
{
"DbId": 423532,
"SchemaName": "db_test@rm-xxx:3306",
"CatalogName": "def",
"SearchName": "db_test",
"DbType": "polardb",
"EnvType": "dev",
"InstanceId": 4325325,
"RegionId": "cn-hangzhou",
"InstanceResourceId": "rm-xxx",
"InstanceSource": "RDS"
}
]
}
}
Error codes
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.