Queries the information about performance metrics of an AnalyticDB for PostgreSQL instance within a time range.
Operation description
You can query monitoring information only within the last 30 days.
Debugging
Authorization information
The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action
policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:
- Operation: the value that you can use in the Action element to specify the operation on a resource.
- Access level: the access level of each operation. The levels are read, write, and list.
- Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
- The required resource types are displayed in bold characters.
- If the permissions cannot be granted at the resource level,
All Resources
is used in the Resource type column of the operation.
- Condition Key: the condition key that is defined by the cloud service.
- Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
Operation | Access level | Resource type | Condition key | Associated operation |
---|---|---|---|---|
gpdb:DescribeDBClusterPerformance | get |
|
| none |
Request parameters
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
DBInstanceId | string | Yes | The instance ID. Note
You can call the DescribeDBInstances operation to query details about all AnalyticDB for PostgreSQL instances within a region, including instance IDs.
| gp-bp12ga6v69h86**** |
Key | string | Yes | The performance metric that you want to query. Separate multiple values with commas (,). For more information, see Performance parameters. | adbpg_conn_count |
StartTime | string | Yes | The beginning of the time range to query. Specify the time in the ISO 8601 standard in the Note
You can query monitoring information only within the last 30 days.
| 2021-11-03T15:00Z |
EndTime | string | Yes | The end of the time range to query. Specify the time in the ISO 8601 standard in the Note
The end time must be later than the start time. The maximum time range that can be specified is seven days.
| 2021-11-03T15:10Z |
Nodes | string | No | The nodes for which you want to query performance metrics. Separate multiple values with commas (,). Example: You can also filter the nodes based on their metric values. Valid values:
| top10 |
NodeType | string | No | The node type. Valid values:
Note
If you do not specify this parameter, the performance metrics of all nodes are returned.
| master |
ResourceGroupName | string | No | The name of the resource group. | testgroup |
Response parameters
Examples
Sample success responses
JSON
format
{
"PerformanceKeys": [
{
"Unit": "%",
"Series": [
{
"Values": [
{
"Point": [
"[\"2021-11-03T15:00:00+08:00\",\"5.84\"]"
]
}
],
"Role": "standby",
"Name": "standby-********-cpu"
}
],
"Name": "adbpg_group_cpu_used_percent"
}
],
"EndTime": "2021-11-03T15:10Z",
"RequestId": "8E8990F0-C81E-4C94-8F51-5F**********",
"StartTime": "2021-11-03T15:00Z",
"DBClusterId": "gp-bp12ga6v69h86****"
}
Error codes
For a list of error codes, visit the Service error codes.
Change history
Change time | Summary of changes | Operation |
---|---|---|
2023-12-11 | The request parameters of the API has changed | View Change Details |