Support scheduler visibility and management
Feature Request
Is your feature request related to a problem? Please describe:
It's often difficult to diagnose issues with schedulers and maintain their activation and configuration. This requires the use of pd-ctl, which is not very convenient especially when running in Kubernetes.
Describe the feature you'd like:
I'd like it to be possible to see which schedulers (https://docs.pingcap.com/tidb/stable/glossary#scheduler, https://docs.pingcap.com/tidb/stable/pd-control#scheduler-show--add--remove--pause--resume--config) are enabled in the Dashboard and to turn them on/off and change their configurations using a simple web UI.
Describe alternatives you've considered:
Teachability, Documentation, Adoption, Migration Strategy:
As of tikv/pd#3055 we can list enabled and paused schedulers. However there is no API to list all disabled schedulers, which means we gotta hard-code the built-in scheduler names.
- balance-leader-scheduler
- balance-hot-region-scheduler
- balance-region-scheduler
- label-scheduler
- scatter-range
- balance-adjacent-region-scheduler
- grant-leader-scheduler
- evict-leader-scheduler
- shuffle-leader-scheduler
- shuffle-region-scheduler
- random-merge-scheduler
- shuffle-hot-region-scheduler
Can't we simply add an API to list all available schedulers?
@HunDunDM Can we have an API for all schedulers?
Some schedulers have been deprecated, and some are for testing. I think we need to discuss.