All Products
Search
Document Center

AnalyticDB for PostgreSQL:DescribeDBInstancePerformance

Last Updated:May 09, 2024

Queries the information about performance metrics of an AnalyticDB for PostgreSQL instance within a time range.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer.

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.
OperationAccess levelResource typeCondition keyAssociated operation
gpdb:DescribeDBInstancePerformanceRead
  • All Resources
    *
    none
none

Request parameters

ParameterTypeRequiredDescriptionExample
ResourceGroupIdstringNo

This parameter is no longer used.

rg-bp67acfmxazb4p****
DBInstanceIdstringYes

The instance ID.

Note You can call the DescribeDBInstances operation to query the IDs of all AnalyticDB for PostgreSQL instances within a region.
gp-bp12ga6v69h86****
KeystringYes

The performance metric. Separate multiple values with commas (,). For more information, see Performance parameters.

CpuUsage,MemoryUsage,Gpdb_SpaceUsage,Gpdb_IOPS,Gpdb_session
StartTimestringYes

The beginning of the time range to query. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mmZ format. The time must be in UTC.

2022-07-08T03:47Z
EndTimestringYes

The end of the time range to query. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mmZ format. The time must be in UTC. The end time must be later than the start time.

2022-07-09T03:47Z

Response parameters

ParameterTypeDescriptionExample
object
EndTimestring

The end time of the query.

2022-07-09T03:47Z
StartTimestring

The start time of the query.

2022-07-08T03:47Z
DBInstanceIdstring

The instance ID.

gp-bp12ga6v69h86****
Enginestring

The database engine of the instance.

gpdb
RequestIdstring

The request ID.

5E85244A-AB47-46A3-A3AD-5F307DCB407E
PerformanceKeysarray

The queried performance metrics.

string

The queried performance metrics. Format: {perf1, perf2, perf3, …}.

{ "Key": "MemoryUsage", "GroupValues": [{ "Name": "7198315-1530522046144-1", "Values": "" }, { "Name": "7198315-1530522046144-0", "Values": "" }, {"Values": "", "Name": "master" } ], "Unit": "%", "ValueFormat": "mem_usage"}

Examples

Sample success responses

JSONformat

{
  "EndTime": "2022-07-09T03:47Z",
  "StartTime": "2022-07-08T03:47Z",
  "DBInstanceId": "gp-bp12ga6v69h86****",
  "Engine": "gpdb",
  "RequestId": "5E85244A-AB47-46A3-A3AD-5F307DCB407E",
  "PerformanceKeys": [
    " { \"Key\": \"MemoryUsage\",  \"GroupValues\": [{ \"Name\": \"7198315-1530522046144-1\", \"Values\": \"\" }, { \"Name\": \"7198315-1530522046144-0\",  \"Values\": \"\" }, {\"Values\": \"\",  \"Name\": \"master\" } ],  \"Unit\": \"%\",  \"ValueFormat\": \"mem_usage\"}"
  ]
}

Error codes

For a list of error codes, visit the Service error codes.

Change history

Change timeSummary of changesOperation
No change history