Queries the details of an AnalyticDB for PostgreSQL instance.

Description

This operation is called to query the details of an AnalyticDB for PostgreSQL instance, such as the instance type, network type, and state.

Limits

You can call this operation up to 1,000 times per second per account. If the number of the calls per second exceeds the limit, throttling is triggered and may affect your business. We recommend that you take note of the limit when you call this operation.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

Parameter Type Required Example Description
Action String Yes DescribeDBInstanceAttribute

The operation that you want to perform. Set the value to DescribeDBInstanceAttribute.

DBInstanceId String Yes gp-bp***************

The ID of the instance.

Note You can call the DescribeDBInstances operation to query the details of all AnalyticDB for PostgreSQL instances in a specific region, including instance IDs.

Response parameters

Parameter Type Example Description
RequestId String 51981F2C-4109-53F7-9B95-************

The ID of the request.

Items Array of DBInstanceAttribute

Details of the instance.

DBInstanceAttribute
VpcId String vpc-rj*******************

The ID of the virtual private cloud (VPC).

CreationTime String 2021-11-30T08:34:33Z

The time when the instance was created.

DBInstanceCpuCores Integer 2

The number of CPU cores.

SegmentCounts Integer 1

The number of compute groups.

Note This parameter is available only for instances in reserved storage mode.
StoragePerNode Integer 80

The storage capacity per node. The unit can be one of the valid values of the StorageUnit parameter.

Note This parameter is available only for instances in reserved storage mode.
DBInstanceMemory Long 16

The memory capacity per compute node.

Note For instances in reserved storage mode and Serverless mode, the unit of this parameter is MB. For instances in elastic storage mode, the unit of this parameter is GB.
HostType String 0

The disk type of the compute group. Valid values:

  • 0: SSD
  • 1: HDD
Note This parameter is available only for instances in reserved storage mode.
PayType String Postpaid

The billing method of the instance. Valid values:

  • Postpaid: pay-as-you-go
  • Prepaid: subscription
Tags Array of Tag

The tags of the instance. Each tag is a key-value pair.

Tag
Key String test-key

The key of the tag.

Value String test-value

The value of the tag.

StorageType String cloud_essd

The storage type of the instance. Valid values:

  • cloud_essd: enhanced SSD (ESSD)
  • cloud_efficiency: ultra disk
Note This parameter is available only for instances in elastic storage mode.
AvailabilityValue String 100.0%

The service availability of the instance. Unit: percent (%).

Note This parameter is available only for instances in reserved storage mode.
ReadDelayTime String null

An invalid parameter. It is no longer returned when you call this operation.

CpuCoresPerNode Integer 1

The number of CPU cores per node.

Note This parameter is available only for instances in reserved storage mode.
Port String 5432

The port that is used to connect to the instance.

ConnectionMode String LVS

The access mode of the instance. Valid values:

  • Performance: standard mode
  • Safety: safe mode
  • LVS: Linux Virtual Server (LVS) mode
LockMode String Unlock

The lock mode of the instance. Valid values:

  • Unlock: The instance is not locked.
  • ManualLock: The instance is manually locked.
  • LockByExpiration: The instance is automatically locked due to instance expiration.
  • LockByRestoration: The instance is automatically locked due to instance restoration.
  • LockByDiskQuota: The instance is automatically locked due to exhausted storage space.
EngineVersion String 6.0

The database version of the instance.

StorageUnit String GB SSD

The unit of the storage capacity. Valid values:

  • GB SSD
  • TB SSD
  • GB HDD
Note This parameter is available only for instances in reserved storage mode and Serverless mode.
MemoryPerNode Integer 8

The memory capacity per node. The unit can be one of the valid values of the MemoryUnit parameter.

Note This parameter is available only for instances in reserved storage mode.
ConnectionString String gp-bp***************.gpdb.rds.aliyuncs.com

The endpoint that is used to connect to the instance.

InstanceNetworkType String VPC

The network type of the instance. Valid values:

  • Classic: classic network
  • VPC: VPC
SecurityIPList String 127.0.0.1

The IP address whitelist of the instance.

MemoryUnit String GB

The unit of the memory capacity.

Note This parameter is available only for instances in reserved storage mode.
DBInstanceClassType String x

The instance family of the instance. Valid values:

  • s: shared
  • x: general-purpose
  • d: dedicated
  • h: dedicated host
DBInstanceDescription String gp-bp***************

The description of the instance.

DBInstanceGroupCount String 2

The number of compute groups.

Note This parameter is available only for instances in reserved storage mode.
ExpireTime String 2999-09-08T16:00:00Z

The expiration time of the instance. The time is displayed in UTC.

Note For pay-as-you-go instances, 2999-09-08T16:00:00Z is returned.
DBInstanceNetType String 2

The type of the network interface card (NIC) that is used by the instance. Valid values:

  • 0: Internet
  • 1: internal network
  • 2: VPC
MaintainStartTime String 18:00Z

The start time of the maintenance window.

MaintainEndTime String 22:00Z

The end time of the maintenance window.

LockReason String null

An invalid parameter. It is no longer returned when you call this operation.

DBInstanceStatus String Running

The state of the instance. For more information, see Instance statuses.

RegionId String cn-hangzhou

The region ID of the instance.

DBInstanceDiskMBPS Long 150

The maximum disk throughput of the compute group. Unit: Mbit/s.

Note This parameter is available only for instances in reserved storage mode.
DBInstanceStorage Long 50

The maximum storage capacity per node. Unit: GB.

ZoneId String cn-hangzhou-j

The zone ID of the instance.

MaxConnections Integer 500

The maximum number of concurrent connections to the instance.

Note This parameter is available only for instances in reserved storage mode.
DBInstanceId String gp-bp***************

The ID of the instance.

DBInstanceClass String gpdb.group.segsdx1

The instance type of the instance.

Note This parameter is available only for instances in reserved storage mode.
Engine String gpdb

The database engine of the instance.

DBInstanceCategory String HighAvailability

The edition of the instance. Valid values:

  • Basic: Basic Edition
  • HighAvailability: High-availability Edition
CpuCores Integer 2

The number of CPU cores on the compute node.

MemorySize Long 16

The memory capacity per compute node.

Note For instances in reserved storage mode and Serverless mode, the unit of this parameter is MB. For instances in elastic storage mode, the unit of this parameter is GB.
StorageSize Long 50

The storage capacity. Unit: GB.

SegNodeNum Integer 4

The number of compute nodes.

Note This parameter is available only for instances in elastic storage mode and Serverless mode.
MasterNodeNum Integer 1

The number of coordinator nodes.

DBInstanceMode String StorageElastic

The resource type of the instance. Valid values:

  • Serverless: Serverless mode
  • StorageElastic: elastic storage mode
  • Classic: reserved storage mode
MinorVersion String 6.3.9.0-202204081027

The minor engine version of the instance.

SupportRestore Boolean true

Indicates whether the instance supports backup and restoration.

  • true: The instance supports backup and restoration.
  • false: The instance does not support backup or restoration.
VSwitchId String vsw-bp*******************

The ID of the vSwitch.

EncryptionKey String 0d2470df-da7b-4786-b981-************

The encryption key.

Note This parameter is returned only for instances for which disk encryption is enabled.
EncryptionType String CloudDisk

The type of encryption. Valid values:

  • CloudDisk: disk encryption
Note This parameter is returned only for instances for which disk encryption is enabled.
CoreVersion String mm.v6.3.9.0-202204081027

The number of the minor engine version.

Examples

Sample requests

http(s)://gpdb.aliyuncs.com/?Action=DescribeDBInstanceAttribute
&DBInstanceId=gp-bp***************
&<Common request parameters>

Sample success responses

XML format

HTTP/1.1 200 OK
Content-Type:application/xml

<DescribeDBInstanceAttributeResponse>
    <code>200</code>
    <data>
        <RequestId>51981F2C-4109-53F7-9B95-************</RequestId>
        <Items>
            <DBInstanceAttribute>
                <MasterNodeNum>1</MasterNodeNum>
                <DBInstanceMemory>16</DBInstanceMemory>
                <CpuCoresPerNode>0</CpuCoresPerNode>
                <Port>5432</Port>
                <SegNodeNum>4</SegNodeNum>
                <MemoryPerNode>0</MemoryPerNode>
                <EncryptionKey>0d2470df-da7b-4786-b981-************</EncryptionKey>
                <InstanceNetworkType>VPC</InstanceNetworkType>
                <DBInstanceClassType>x</DBInstanceClassType>
                <SupportRestore>true</SupportRestore>
                <DBInstanceCategory>HighAvailability</DBInstanceCategory>
                <MaintainEndTime>22:00</MaintainEndTime>
                <DBInstanceId>gp-bp***************</DBInstanceId>
                <DBInstanceStorage>50</DBInstanceStorage>
                <DBInstanceDescription>gp-bp***************</DBInstanceDescription>
                <MaintainStartTime>18:00Z</MaintainStartTime>
                <Engine>gpdb</Engine>
                <Tags>
                    <Tag>
                        <Value>test-value</Value>
                        <Key>test-key</Key>
                    </Tag>
                </Tags>
                <SegmentCounts>0</SegmentCounts>
                <MemorySize>16</MemorySize>
                <EncryptionType>CloudDisk</EncryptionType>
                <MemoryUnit/>
                <StorageType>cloud_essd</StorageType>
                <EngineVersion>6.0</EngineVersion>
                <DBInstanceStatus>Running</DBInstanceStatus>
                <ZoneId>cn-hangzhou-j</ZoneId>
                <DBInstanceCpuCores>2</DBInstanceCpuCores>
                <VSwitchId>vsw-bp*******************</VSwitchId>
                <StorageSize>50</StorageSize>
                <MinorVersion>6.3.5.7-202111221001</MinorVersion>
                <CoreVersion>mm.v6.3.9.0-202204081027</CoreVersion>
                <StorageUnit/>
                <PayType>Postpaid</PayType>
                <LockMode>Unlock</LockMode>
                <VpcId>vpc-rj*******************</VpcId>
                <StoragePerNode>0</StoragePerNode>
                <DBInstanceMode>StorageElastic</DBInstanceMode>
                <CreationTime>2021-11-30T08:34:33Z</CreationTime>
                <ConnectionMode>LVS</ConnectionMode>
                <CpuCores>2</CpuCores>
                <RegionId>cn-hangzhou</RegionId>
                <ConnectionString>gp-bp***************.gpdb.rds.aliyuncs.com</ConnectionString>
                <ExpireTime>2999-09-08T16:00:00Z</ExpireTime>
            </DBInstanceAttribute>
        </Items>
    </data>
    <httpStatusCode>200</httpStatusCode>
    <requestId>51981F2C-4109-53F7-9B95-************</requestId>
    <successResponse>true</successResponse>
</DescribeDBInstanceAttributeResponse>

JSON format

HTTP/1.1 200 OK
Content-Type:application/json

{
  "code" : "200",
  "data" : {
    "RequestId" : "51981F2C-4109-53F7-9B95-************",
    "Items" : {
      "DBInstanceAttribute" : [ {
        "MasterNodeNum" : 1,
        "DBInstanceMemory" : 16,
        "CpuCoresPerNode" : 0,
        "Port" : "5432",
        "SegNodeNum" : 4,
        "MemoryPerNode" : 0,
        "EncryptionKey" : "0d2470df-da7b-4786-b981-************",
        "InstanceNetworkType" : "VPC",
        "DBInstanceClassType" : "x",
        "SupportRestore" : true,
        "DBInstanceCategory" : "HighAvailability",
        "MaintainEndTime" : "22:00",
        "DBInstanceId" : "gp-bp***************",
        "DBInstanceStorage" : 50,
        "DBInstanceDescription" : "gp-bp***************",
        "MaintainStartTime" : "18:00Z",
        "Engine" : "gpdb",
        "Tags" : {
          "Tag" : [ {
            "Value" : "test-value",
            "Key" : "test-key"
          } ]
        },
        "SegmentCounts" : 0,
        "MemorySize" : 16,
        "EncryptionType" : "CloudDisk",
        "MemoryUnit" : "",
        "StorageType" : "cloud_essd",
        "EngineVersion" : "6.0",
        "DBInstanceStatus" : "Running",
        "ZoneId" : "cn-hangzhou-j",
        "DBInstanceCpuCores" : 2,
        "VSwitchId" : "vsw-bp*******************",
        "StorageSize" : 50,
        "MinorVersion" : "6.3.5.7-202111221001",
        "CoreVersion" : "mm.v6.3.9.0-202204081027",
        "StorageUnit" : "",
        "PayType" : "Postpaid",
        "LockMode" : "Unlock",
        "VpcId" : "vpc-rj*******************",
        "StoragePerNode" : 0,
        "DBInstanceMode" : "StorageElastic",
        "CreationTime" : "2021-11-30T08:34:33Z",
        "ConnectionMode" : "LVS",
        "CpuCores" : 2,
        "RegionId" : "cn-hangzhou",
        "ConnectionString" : "gp-bp***************.gpdb.rds.aliyuncs.com",
        "ExpireTime" : "2999-09-08T16:00:00Z"
      } ]
    }
  },
  "httpStatusCode" : "200",
  "requestId" : "51981F2C-4109-53F7-9B95-************",
  "successResponse" : true
}

Error codes

For a list of error codes, visit the API Error Center.