PolarDB clusters provide private and public endpoints for database connections. This topic describes how to modify or delete an endpoint in the PolarDB console.
Prerequisites
Before you begin, ensure that you have:
A PolarDB for PostgreSQL cluster (centralized or distributed)
Access to the PolarDB console
Modify an endpoint
The steps differ depending on whether your cluster is a centralized cluster (Enterprise Edition or Standard Edition) or a distributed cluster.
If SSL is enabled for the endpoint, the cluster restarts after the modification completes.
Centralized cluster
Log on to the PolarDB console. In the left-side navigation pane, click Clusters. In the upper-left corner of the page, select the region where the cluster resides, then click the cluster ID to go to the Basic Information page.
In the Database Connection section, find the endpoint and choose
> Edit to the right of Private or Public to modify the endpoint.
Endpoint requirements:
| Requirement | Details |
|---|---|
| Prefix length | 6–40 characters |
| Allowed characters | Lowercase letters, digits, and hyphens (-) |
| Start character | Lowercase letter |
| End character | Digit or letter |
| Port number | 1000–5999 |
| SSL enabled (max length) | Total endpoint length cannot exceed 64 characters |
Distributed cluster
Log on to the PolarDB console. In the left-side navigation pane, click Clusters. In the upper-left corner of the page, select the region where the cluster resides, then click the cluster ID to go to the Basic Information page.
In the Database Connection section, find the endpoint and click
to the right of Private or Public to modify the endpoint.
In the dialog box, specify a prefix for the endpoint and click OK.
The prefix must be 6–40 characters, contain only lowercase letters, digits, and hyphens (-), start with a lowercase letter, and end with a digit or letter. The port must be in the range 1000–5999.
Delete an endpoint
Only public endpoints can be deleted. You cannot delete the public endpoint of a PolarDB for PostgreSQL distributed cluster. Before deleting an endpoint, make sure your application connects to the cluster through a different endpoint. Deleted endpoints cannot be restored. To obtain a new endpoint, click Apply next to the required endpoint type in the console.
The default cluster endpoint can be modified but not deleted. Only custom cluster endpoints can be deleted.
Log on to the PolarDB console. In the left-side navigation pane, click Clusters. In the upper-left corner of the page, select the region where the cluster resides, then click the cluster ID to go to the Basic Information page.
In the Database Connection section, find the endpoint and choose
> Release to the right of Public to delete the endpoint.
API reference
| Operation | Description |
|---|---|
| DescribeDBClusterEndpoints | Queries the endpoints of a PolarDB cluster. |
| CreateDBEndpointAddress | Creates a public endpoint for a PolarDB cluster. |
| ModifyDBEndpointAddress | Modifies the default endpoint of a PolarDB cluster. |
| DeleteDBEndpointAddress | Deletes a cluster endpoint of a PolarDB cluster. |