pingcap / pingcap/tidb-operator

[Feature] Auto Scaling for TiDB/TiKV in TiDB Operator

Open
#6,622 0 comments 2 reactions 1 assignee View on GitHub

@King-Dylan is already working on this.

Since Dec 23, 2025.

cloud/aws enhancement
Dominant language
Go
Stars
1.3k
Forks
540
Avg merge
3d 2h
Merged PRs (30d)
18

Description

Description

Scaling TiDB/TiKV today requires manually updating TidbCluster.spec.replicas. This issue proposes an optional auto-scaling controller that periodically reads metrics (e.g. Prometheus) and automatically adjusts replicas via TiDB Operator.

MVP Requirements
  • Triggers: CPU / memory (TiDB); + storage (TiKV)
  • Guards: threshold + sustained duration, cool-down
  • Safety: min/max/step replica limits, multi-AZ balance, scale-in maintenance window
  • Failure handling: retry + timeout, optional rollback, clear events/logs
Phases
  • Phase 1: TiDB auto scaling
  • Phase 2: TiKV auto scaling (adds storage + data balancing considerations)

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.