Querying Details of a Schema
Function
This API is used to query details about a schema.
Constraints
None
URI
GET /v1/{project_id}/instances/{instance_id}/databases/{ddm_dbname}
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
project_id |
Yes |
String |
Project ID |
instance_id |
Yes |
String |
DDM instance ID |
ddm_dbname |
Yes |
String |
Name of the schema to be queried, which is case-insensitive |
Request Parameters
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
X-Auth-Token |
Yes |
String |
User token It can be obtained by calling the IAM API (value of X-Subject-Token in the response header). |
Response Parameters
Status code: 200
Parameter |
Type |
Description |
---|---|---|
database |
GetDDMDatabaseResponseBean object |
Schema information |
Parameter |
Type |
Description |
---|---|---|
name |
String |
Schema name |
created |
String |
Time when the schema is created |
status |
String |
Schema status |
updated |
String |
Time when the DDM instance is last updated |
databases |
Array of GetDDMDatabases objects |
Sharding information of the schema |
shard_mode |
String |
Working mode of the schema
|
shard_number |
Integer |
Number of shards in the same working mode |
shard_unit |
Integer |
Number of shards per RDS DB instance |
dataVips |
Array of strings |
IP address and port number for connecting to the schema |
used_rds |
Array of GetDDMDatabaseUsedrds objects |
Associated RDS DB instances |
Parameter |
Type |
Description |
---|---|---|
dbslot |
Integer |
Number of shards |
name |
String |
Shard name |
status |
String |
Schema status |
created |
String |
Time when the schema is created |
updated |
String |
Time when the schema is last updated |
id |
String |
ID of the RDS DB instance where the shard is located |
idName |
String |
Name of the RDS DB instance |
Parameter |
Type |
Description |
---|---|---|
id |
String |
Node ID of the associated RDS DB instance |
name |
String |
Name of the associated RDS DB instance |
status |
String |
Status of the associated RDS DB instance |
error_msg |
String |
Response message. This parameter is not returned if no error occurs. |
Status code: 400
Parameter |
Type |
Description |
---|---|---|
errCode |
String |
Service error code |
externalMessage |
String |
Error message |
Example Request
GET https://{endpoint} /v1/{project_id}/instances/{instance_id}/databases/{ddm_dbname}
Example Response
Status code: 200
OK
{ "database" : { "databases" : [ "id:ea81976b12e84d57822209169caddc11in01", "name:db_2305", "idName:db_2305", "status:RUNNING", "dbSlot:0", "created:1603861296004", "updated:1603861296004" ], "dataVips" : [ "92.168.0.175:5066" ], "status" : "RUNNING", "created" : "0f58c8dc-4a78-42e6-9811-565679de8e9e", "name" : "db_2305", "updated" : "1604282063035", "shard_mod" : "single", "shard_number" : "1", "shard_unit" : "1", "used_rds" : [ "id:ea81976b12e84d57822209169caddc11in01", "status:RUNNING", "nam:rds-94c3-wuli" ] } }
Status code: 400
bad request
{ "externalMessage" : "Parameter error.", "errCode" : "DBS.280001" }
Status Codes
For details, see Status Codes.
Error Codes
For details, see Error Codes.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot