All Products
Search
Document Center

ApsaraDB for MongoDB:SQL throttling

Last Updated:Mar 28, 2026

When a traffic surge hits a specific collection — such as a burst of find queries driving CPU utilization up — SQL throttling lets you cap the number of concurrent find, insert, update, and delete operations on that collection. Requests that exceed the cap are blocked until concurrency drops back below the threshold, protecting overall database availability and stability.

Prerequisites

Before you begin, make sure your instance version meets the following requirements:

Major versionMinimum minor version
5.06.0.13
6.07.0.9
7.08.0.4
8.0All minor versions except 9.0.5

Create a throttling rule

  1. Go to the MongoDB Replica Set Instances page or the MongoDB Sharded Cluster Instances page. Select a resource group and region at the top of the page, then click the ID of the target instance.

  2. In the left navigation pane, choose CloudDBA > Sessions.

  3. Click Session Throttling.

  4. On the Session Throttling page, click Create Throttling Rule.

  5. In the dialog box, configure the following parameters.

    ParameterDescription
    Operation typeThe operations to throttle. Select one or more: find, insert, update, delete.
    operation concurrency valueThe maximum number of concurrent executions allowed for the selected operations. Requests that exceed this threshold are throttled.
    Rate Limiting DurationHow long the rule stays active. After the duration ends, the rule expires automatically and moves to the Ended tab.
    Kill Statement(Optional) When enabled, the system immediately terminates all active operations that match the rule the moment the rule takes effect. This runs once to release connections and compute resources held by long-running operations. New requests that arrive after the rule is active are blocked by the throttling mechanism — they are not killed. Enable this option when a load burst has caused many long-running transactions to accumulate and you need to free resources immediately.
    Rate Limiting ScopeAvailable for sharded cluster instances only. Apply the rule to All Shards or Partial Shards.
    Rate Limiting CollectionThe collection to throttle. Use the format databaseName.collectionName.
  6. Click Submit.

Manage throttling rules

After a rule is created, you can manage it from the Session Throttling page:

TabAvailable actions
RunningView, modify, or disable an active throttling rule.
EndedView or re-enable an expired throttling rule.