ApsaraDB for Redis instances with cloud disks are based on the new-generation control architecture of ApsaraDB for Redis. These instances allow you to adjust the number of shards and support smooth scaling. Transient connections do not occur and the instance does not enter the read-only state during scaling. This allows you to handle read/write hotspots and data skews more flexibly.

Prerequisites

The instance is a persistent memory-optimized instance of the cluster architecture.

Usage notes

  • An instance can contain 1 to 32 shards.
  • You cannot schedule the operation to be performed in a maintenance window. After you adjust the number of shards, the instance immediately enters the Changing Configuration state and automatically adjusts data on the shards for even distribution.
  • The duration of a specification change is based on multiple factors such as the network conditions, task queue size, and data volume. A specification change may cause a latency fluctuation. We recommend that you change specifications during off-peak hours. Make sure that your applications can automatically reconnect to instances.

Pricing

For more information, see Specification changes.

Procedure

  1. Log on to the ApsaraDB for Redis console.
  2. In the top navigation bar of the page, select the region where the instance is deployed.
  3. On the Instances page, click the ID of the instance.
  4. In the Shard Information section, perform the following operations based on your business requirements.
    Figure 1. Adjust the number of shards
    Adjust the number of shards
    • Add shards
      1. Click Add Shard.
      2. In the panel that appears, set the number of shards that you want to add to the instance.
        Note The specifications of the shards to be added are the same as those of existing shards and cannot be modified.
      3. Click Pay and complete the payment.
    • Delete shards
      1. Click Delete Shard.
        Note You can also click Delete in the Actions column of the shard to be deleted.
      2. In the dialog box that appears, select the shards to be deleted from the drop-down list. You can also click Delete All Shards and remove the shards that you want to retain to delete all the other shards.
      3. Click OK.

Related operations

Operation Description
AddShardingNode Adds shards to an ApsaraDB for Redis cluster instance.
DeleteShardingNode Deletes shards from an ApsaraDB for Redis cluster instance.