pingcap / tidb

TiDB - the open-source, cloud-native, distributed SQL database designed for modern applications.
https://pingcap.com
Apache License 2.0
37.34k stars 5.85k forks source link

Restore should scatter new created empty tables #57596

Open 3pointer opened 1 day ago

3pointer commented 1 day ago

Enhancement

Context: https://github.com/pingcap/tidb/issues/55184

Starting from TiDB v8.4, the tidb_scatter_region variable supports global scope region scattering. To take advantage of this feature, BR should set this variable to global before creating tables.

Without this configuration, empty tables will not be scattered across the cluster and may instead concentrate on a few TiKV nodes. This uneven distribution increases the likelihood of triggering hotspot issues.