This topic introduces the short-lived connection optimization function provided by ApsaraDB RDS for MySQL in its dedicated proxy feature.

Prerequisites

The dedicated proxy feature is enabled. For more information, see Dedicated proxy.

Background information

After a user terminates their connection with an RDS instance, the dedicated proxy of the RDS instance checks whether this connection is idle. If this connection is idle, the dedicated proxy releases its connection with the user, but retains its connection with the RDS instance in the connection pool for a specific retention period. If the user requests to connect to the RDS instance again within the retention period, the dedicated proxy retrieves its connection with the RDS instance from the connection pool to reduce overheads.

Procedure

  1. Log on to the ApsaraDB for RDS console.
  2. In the upper-left corner of the page, select the region where the target RDS instance resides.
    Select a region
  3. Find the target RDS instance and click its ID.
  4. In the left-side navigation pane, click Database Proxy.
  5. In the Proxy Endpoint section of the Proxy Service tab, click Enable to the right of Short-Lived Connection Optimization.
    Note
    • When you no longer need short-lived connection optimization, you can click Disable to the right of Short-Lived Connection Optimization to disable it.
    • After you enable or disable short-lived connection optimization, the setting takes effect immediately.