After the database proxy feature is enabled for an ApsaraDB RDS for MySQL instance, your client can connect to the database system over a database proxy endpoint. This topic describes the types of database proxy endpoints and how to configure a database proxy endpoint, internal endpoint, and public endpoint.
Prerequisites
The database proxy feature is enabled. For more information, see Enable the database proxy feature.
Types of database proxy endpoints
Database proxy endpoints are classified into the following types: internal endpoints of the virtual private cloud (VPC) type, internal endpoints of the classic network type, and public endpoints.
When you enable the database proxy feature for your RDS instance, a database proxy endpoint is automatically generated, which is also called the default database proxy endpoint and cannot be deleted. Database proxy endpoints are formerly known as proxy terminals. For more information, see Enable the database proxy feature.
Each RDS instance with the database proxy feature enabled supports up to seven database proxy endpoints. You can apply for one internal endpoint of the VPC type and one public endpoint for each database proxy endpoint.
Starting December 07, 2023, you can no longer apply for a database proxy endpoint of the classic network type when you create a database proxy endpoint for an ApsaraDB RDS for MySQL instance. If you have applied for an internal endpoint of the classic network type, you can continue to use the internal endpoint. However, if you release the internal endpoint of the classic network type, you can no longer apply for an internal endpoint of the classic network type. For more information, see [EOS/Discontinuation] Internal endpoints of the classic network type can no longer be created for database proxies in ApsaraDB RDS for MySQL.
Manage database proxy endpoints
Create a database proxy endpoint (formerly proxy terminal)
After you enable the database proxy feature, you can add database proxy endpoints and configure connection policies for each database proxy endpoint to meet your business requirements.
A single RDS instance supports up to seven database proxy endpoints.
Go to the Instances page. In the top navigation bar, select the region in which the RDS instance resides. Then, find the RDS instance and click the ID of the instance.
In the left-side navigation pane, click Database Proxy.
In the Connection Information section, click Create Proxy Endpoint.
In the dialog box that appears, configure the connection settings and click OK. For more information, see Configure the connection settings for a database proxy endpoint.
Change the vSwitch of a database proxy endpoint
Log on to the ApsaraDB RDS console and go to the Instances page. In the top navigation bar, select the region in which the RDS instance resides. Then, find the RDS instance and click the instance ID.
In the left-side navigation pane, click Database Proxy.
In the Connection Information section, find the database proxy endpoint that you want to manage and click Switch vSwitch in the Network Settings column.
ImportantWhen you change the vSwitch of a database proxy endpoint, a transient connection that lasts approximately 30 seconds occurs. If you use the endpoint of the RDS instance to connect to the RDS instance, your workloads are not affected. Before you change the vSwitch, we recommend that you use the endpoint of the primary RDS instance or the read-only routing endpoint to connect to the RDS instance. Alternatively, you can change the vSwitch during off-peak hours. Make sure that your application is configured to automatically reconnect to your RDS instance.
In the dialog box that appears, configure Destination vSwitch and Change Time and click OK.
Modify a database proxy endpoint and the port that is associated with the database proxy endpoint
Log on to the ApsaraDB RDS console and go to the Instances page. In the top navigation bar, select the region in which the RDS instance resides. Then, find the RDS instance and click the instance ID.
In the left-side navigation pane, click Database Proxy.
In the Connection Information section, click the icon to the right of the database proxy endpoint.
In the dialog box that appears, modify the values of Endpoint and Port. Then, click OK. The value of Endpoint that you can modify refers to the prefix of the database proxy endpoint.
If you upgrade a database proxy of your RDS instance from a shared database proxy to a dedicated database proxy and modify the database proxy endpoint for the first time, the suffix of the database proxy endpoint is automatically changed. Take note of the change made to the suffix of the database proxy endpoint.
Delete a database proxy endpoint
Go to the Instances page. In the top navigation bar, select the region in which the RDS instance resides. Then, find the RDS instance and click the instance ID.
In the left-side navigation pane, click Database Proxy.
Find the database proxy endpoint that you want to delete and click Delete Connection in the Actions column. In the message that appears, click OK.
You must retain at least one database proxy endpoint for the RDS instance.
Once the database proxy endpoint is released, the ID, internal endpoint, and public endpoint of the database proxy endpoint are also deleted.
Manage a public endpoint of the database proxy endpoint
Apply for a public endpoint
You can apply for a public endpoint on the Database Proxy page or the Database Connection page.
Perform operations on the Database Proxy page
Go to the Instances page. In the top navigation bar, select the region in which the RDS instance resides. Then, find the RDS instance and click the instance ID.
In the left-side navigation pane, click Database Proxy.
In the Connection Information section, find the required database proxy endpoint and click Apply for Public Endpoint in the Internet Endpoint/Port column.
In the dialog box that appears, configure Proxy Endpoint and Port, and then click OK.
Perform operations on the Database Connection page
Go to the Instances page. In the top navigation bar, select the region in which the RDS instance resides. Then, find the RDS instance and click the instance ID.
In the left-side navigation pane of the instance details page, click Database Connection.
In the Database Proxy Connection section, click Apply for Public Endpoint, configure Proxy Endpoint and Port, and then click OK. The value of Proxy Endpoint that you can modify refers to the prefix of the database proxy endpoint.
You can apply for only one public endpoint for each database proxy endpoint.
The prefix of a database proxy endpoint must be 2 to 40 characters in length and can contain letters, digits, and hyphens (-). The prefix must start with a lowercase letter.
The port number that is associated with a database proxy endpoint must be within the range of 1000 to 5999.
Release a public endpoint
You can release a public endpoint in the following two ways:
Perform operations on the Database Proxy page
Go to the Instances page. In the top navigation bar, select the region in which the RDS instance resides. Then, find the RDS instance and click the instance ID.
In the left-side navigation pane, click Database Proxy.
Find the required database proxy endpoint and click Release Public Endpoint in the Public Endpoint/Port column. In the dialogue box that appears, click OK.
Perform operations on the Database Connection page
Go to the Instances page. In the top navigation bar, select the region in which the RDS instance resides. Then, find the RDS instance and click the instance ID.
In the left-side navigation pane of the instance details page, click Database Connection.
In the Database Proxy Endpoint section, click Release Public Endpoint in the Public Endpoint/Port column. In the dialogue box that appears, click OK.
References
Related operations
Operation | Description |
Queries the details about the database proxy of an instance. | |
Queries the information about the database proxy endpoints of an instance. | |
Modifies the proxy endpoint settings of the database proxy of an instance. | |
Creates a database proxy endpoint. | |
Modifies a database proxy endpoint. | |
Deletes a database proxy endpoint. |