Serverless ApsaraDB RDS for PostgreSQL instances scale RDS Capacity Units (RCUs) automatically. When RCU scaling may cause a transient connection, the Scaling Policy setting determines what happens next: ignore the request to preserve availability, or force the change immediately to preserve performance.
How it works
When the instance needs to scale RCUs, it checks whether applying the change may cause a transient connection. The result depends on the scaling policy:
| Do Not Execute Forcefully (default) | Execute Forcefully | |
|---|---|---|
| When scaling may cause a transient connection | Ignores the scaling request | Forces the RCU change immediately regardless of the instance status or transient connections |
| Effect on availability | Preserved — no connection drops | May cause a transient connection lasting approximately 1 minute |
| Effect on performance | May degrade if scaling is deferred | Maintained — scaling always executes |
| Best for | Workloads that cannot tolerate connection interruptions | Workloads that require consistent performance and can recover from dropped connections |
Transient connections are emergency countermeasures. The probability of a transient connection occurring is extremely low.
Prerequisites
Before you begin, ensure that you have:
A serverless ApsaraDB RDS for PostgreSQL instance (billing method: Serverless)
Change the scaling policy
Option 1: During instance creation
Set the Scaling Policy parameter when creating a new serverless instance. For details, see Create a serverless ApsaraDB RDS for PostgreSQL instance.
Option 2: Using the console
Go to the Instances page. In the top navigation bar, select the region where the instance resides, then click the instance ID.
In the Configuration Information section, click Modify Scaling Settings.
Click Advanced Settings. In the Scaling Policy drop-down list, select an option: Click OK.
Do Not Execute Forcefully (default): The instance ignores the scaling request if it may cause a transient connection. Choose this option for workloads that cannot tolerate interruptions.
Execute Forcefully: The instance scales RCUs immediately regardless of the instance status or transient connections. A transient connection lasting approximately 1 minute may occur. Choose this option if consistent performance matters more than uninterrupted availability.
Option 3: Via API
Call the ModifyDBInstanceSpec operation with the following parameters:
| Parameter | Description | Example |
|---|---|---|
DBInstanceId | ID of the serverless instance | pgm-**** |
PayType | Billing method | Serverless |
Direction | Configuration change type | Serverless |
ServerlessConfiguration.SwitchForce | Whether to force RCU scaling | true (Execute Forcefully) / false (Do Not Execute Forcefully, default) |
What's next
To adjust the RCU range for peak or off-peak hours, see Change the scaling range of RCUs.
To reduce costs when no connections are active, configure automatic suspension. See Configure the automatic start and stop feature.