Queries the endpoints of a PolarDB cluster.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
polardb:DescribeDBClusterEndpoints |
get |
*dbcluster
|
None | None |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| DBClusterId |
string |
Yes |
The ID of the cluster. Note
You can call the DescribeDBClusters operation to find the IDs of all clusters in your account. |
pc-************* |
| DBEndpointId |
string |
No |
The ID of the cluster endpoint. |
pe-************* |
| DescribeType |
string |
No |
Specifies whether to return information about AI nodes. |
AI |
| PolarFsInstanceId |
string |
No |
The ID of the PolarFS instance. |
pfs-test***** |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
|||
| RequestId |
string |
The request ID. |
2DC120BF-6EBA-4C63-BE99-B09F9E****** |
| Items |
array<object> |
A list of cluster endpoints. |
|
|
array<object> |
|||
| Nodes |
string |
The list of nodes configured for the endpoint. |
pi-***************,pi-*************** |
| ReadWriteMode |
string |
The read/write mode. Valid values:
|
ReadOnly |
| AddressItems |
array<object> |
The connection addresses for the endpoint. |
|
|
object |
|||
| VSwitchId |
string |
The vSwitch ID. |
vsw-************ |
| PrivateZoneConnectionString |
string |
The connection string for the private domain name. |
***.***.**.com |
| ConnectionString |
string |
The connection string. |
********.rwlb.polardb-pg-public.rds.aliyuncs.com |
| NetType |
string |
The network type. Valid values:
|
Private |
| Port |
string |
The port. |
1521 |
| VpcInstanceId |
string |
The VPC instance ID. Note
This parameter is returned only for PolarDB for MySQL clusters. |
pe-************* |
| VPCId |
string |
The VPC ID. |
vpc-*************** |
| IPAddress |
string |
The IP address. |
192.***.***.*** |
| DashboardUsed |
boolean |
Indicates whether the endpoint is a dashboard endpoint for a PolarDB Search node.
|
True |
| DBEndpointId |
string |
The endpoint ID. |
pe-************* |
| EndpointConfig |
string |
The advanced settings for the cluster endpoint.
|
{\"DistributedTransaction\":\"off\",\"ConsistLevel\":\"0\",\"LoadBalanceStrategy\":\"load\",\"MasterAcceptReads\":\"on\"} |
| DBEndpointDescription |
string |
The endpoint name. |
test |
| EndpointType |
string |
The type of the cluster endpoint. Valid values:
|
Custom |
| AutoAddNewNodes |
string |
Indicates whether new nodes are automatically added to the default cluster endpoint. Valid values:
|
Enable |
| DBClusterId |
string |
The cluster ID. |
pc-bp1s826a1up****** |
| SccMode |
string |
Indicates whether global consistency (high-performance mode) is enabled for the node. Valid values:
|
on |
| PolarSccTimeoutAction |
string |
The policy for handling global consistency read timeouts. Valid values:
|
0 |
| PolarSccWaitTimeout |
string |
The timeout period for global consistency reads. |
100 |
| NodeWithRoles |
string |
The role of each node in the endpoint. The primary node has the Writer role. Read-only nodes have numbered roles, such as Reader1, Reader2, and so on. Note
This parameter is supported only by PolarDB for PostgreSQL clusters and PolarDB for PostgreSQL (compatible with Oracle) clusters. |
Reader1 |
| ServiceName |
string |
The service name. |
test-name |
| NetType |
string |
The network type. Valid values:
|
Private |
| VPCId |
string |
The VPC ID. |
vpc-*************** |
| Port |
string |
The port. |
1521 |
| ConnectionString |
string |
The connection string. |
********.rwlb.polardb-pg-public.rds.aliyuncs.com |
| Protocol |
string |
The protocol type. |
http |
Examples
Success response
JSON format
{
"RequestId": "2DC120BF-6EBA-4C63-BE99-B09F9E******",
"Items": [
{
"Nodes": "pi-***************,pi-***************",
"ReadWriteMode": "ReadOnly",
"AddressItems": [
{
"VSwitchId": "vsw-************",
"PrivateZoneConnectionString": "***.***.**.com",
"ConnectionString": "********.rwlb.polardb-pg-public.rds.aliyuncs.com",
"NetType": "Private",
"Port": "1521",
"VpcInstanceId": "pe-*************",
"VPCId": "vpc-***************",
"IPAddress": "192.***.***.***",
"DashboardUsed": true
}
],
"DBEndpointId": "pe-*************",
"EndpointConfig": "{\\\"DistributedTransaction\\\":\\\"off\\\",\\\"ConsistLevel\\\":\\\"0\\\",\\\"LoadBalanceStrategy\\\":\\\"load\\\",\\\"MasterAcceptReads\\\":\\\"on\\\"}",
"DBEndpointDescription": "test",
"EndpointType": "Custom",
"AutoAddNewNodes": "Enable",
"DBClusterId": "pc-bp1s826a1up******",
"SccMode": "on",
"PolarSccTimeoutAction": "0",
"PolarSccWaitTimeout": "100",
"NodeWithRoles": "Reader1",
"ServiceName": "test-name",
"NetType": "Private",
"VPCId": "vpc-***************",
"Port": "1521",
"ConnectionString": "********.rwlb.polardb-pg-public.rds.aliyuncs.com",
"Protocol": "http"
}
]
}
Error codes
|
HTTP status code |
Error code |
Error message |
Description |
|---|---|---|---|
| 404 | InvalidDBCluster.NotFound | The DBClusterId provided does not exist in our records. | The specified DBClusterId parameter does not exist in the current record. |
| 404 | InvalidDBClusterId.NotFound | The DBClusterId provided does not exist in our records. | The specified DBClusterId parameter does not exist in the current record. |
| 404 | InvalidDBClusterId.Malformed | The specified parameter DBClusterId is not valid. | The specified DBClusterId parameter is invalid. |
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.