Label tidb workers
- Dominant language
- Go
- Stars
- 40.5k
- Forks
- 6.2k
- PR merge metrics
- PR metrics pending
Description
## Enhancement
The distributed background task parallel execution framework(brief: the framework) requires multiple TiDB servers to serve as scheduler and execute real subtasks for task. In the previous implementation, all TiDB servers can be selected as candidate workers by default. However, given the resource-intensive nature of distributed tasks, it is important to ensure smooth operation of both foreground and background tasks without interference.
To address this, we aim to provide users with the flexibility to designate specific TiDB servers as tidb_role "background“.
```
[labels]
tidb_role = "background"
```
These labeled tidb servers will be dedicated to running distributed tasks, while other servers will not be involved in these operations. This approach allows users to manage resource allocation effectively and ensure optimal performance for both foreground and background tasks.
The disttask framework will select tidb nodes with "background" label to run tasks.
If the tidb_role = "all", TiDB will run all tasks.
If the tidb_role="regular", TiDB will not run tasks.
Contributor guide
Assessment
This issue has not been assessed yet.