You can configure the parameters for automatic configuration changes on the Basic Information page of your PolarDB for MySQL cluster. The PolarDB for MySQL cluster automatically scales out or scales in based on the parameters that you configure. This topic describes how to configure the parameters for automatic configuration changes on the Basic Information page of a PolarDB for MySQL cluster.

Limits

  • The edition of the PolarDB for MySQL cluster is Cluster or Archive Database Cluster Edition. Single Node and Archive Database (High Compression Ratio) are not supported. For more information about cluster editions, see Editions.
  • No upgrade or downgrade task is being performed for the PolarDB cluster.
  • PolarDB for MySQL clusters that use the pay-as-you-go and subscription billing methods all support auto scaling.

Billing

For information about the billing rules, see Configuration change fees.

Precautions

  • You can upgrade or downgrade only clusters. You cannot upgrade or downgrade a single node in a cluster.
  • When you upgrade or downgrade a cluster, data stored in the cluster is not affected.
  • During the upgrade or downgrade process, your applications are temporarily disconnected from the cluster for no more than 30 seconds. We recommend that you upgrade or downgrade your cluster during off-peak hours and make sure that your applications are configured with the automatic reconnection mechanism.
  • A cluster upgrade or downgrade has minor impacts on the primary node of a PolarDB cluster. However, the upgrade or downgrade degrades the performance of read-only nodes in the cluster. As a result, the read-only nodes require more time to handle requests during the upgrade or downgrade process.

Procedure

  1. Log on to the PolarDB console.
  2. In the upper-left corner of the console, select the region where the cluster that you want to manage is deployed.
  3. On the Clusters page, click the ID of the cluster.
  4. On the Overview page, click Settings in the upper-right corner of the Database Nodes section.
    Settings
  5. In the dialog box that appears, specify the following parameters. The following table describes the parameters.
    Parameter Description
    Auto Scaling-out Specifies whether to enable the auto scale-out feature.
    Observation Period If the CPU utilization is greater than or equal to the specified value during the observation period, PolarDB automatically adds nodes or upgrades the specifications of your cluster after the observation period expires. This ensures that the cluster can handle the incoming read and write requests. For example, if the observation period is 5 minutes and the time required to complete a scaling activity is 10 minutes, you must wait 15 minutes before you can check the scaling result.
    CPU Usage The threshold that is used to trigger upgrades or scale-out activities. If the CPU Usage is greater than or equal to the specified value, an auto scale-out activity is triggered.
    Maximum Specification The highest specifications to which a cluster can be upgraded. After an upgrade is triggered, the specifications of a PolarDB cluster is upgraded tier by tier until the highest specifications are applied. For example, the cluster is upgraded from 4 cores to 8 cores, and then to 16 cores.
    Maximum Number of Read-only Nodes The maximum number of read-only nodes that can be automatically added to the cluster. After a scale-out activity is triggered, read-only nodes are automatically added to a PolarDB cluster one after another until the specified upper limit is reached.
    Note The nodes that are automatically added are associated with the default cluster endpoint. If the cluster uses a custom endpoint, you must specify whether to associate these nodes with the endpoint by specifying the Automatically Associate New Nodes parameter. For more information about Automatically Associate New Nodes, see Configure PolarProxy.
    Auto Scaling-in Specifies whether to enable the auto scale-in feature.
    Note After you turn on Auto Scaling-in, if the CPU utilization remains at less than 30% for more than 99% of the silent period, an automatic scale-in activity is triggered after the silent period ends. The specifications of the PolarDB cluster are scaled in to the original specifications in small increments.
    Quiescent Period The minimum interval between two scaling activities. During a silent period, PolarDB monitors the resource usage of a cluster but does not trigger scaling activities. If a quiescent period and an observation period end at the same time and the CPU utilization reaches the threshold value within the observation period, PolarDB automatically triggers the auto scaling operation.
  6. Click OK.