make DumpStatsToJSON and LoadStatsFromJSON don't depend on handle
Open
sig/planner
type/enhancement
- Dominant language
- Go
- Stars
- 40.5k
- Forks
- 6.2k
- PR merge metrics
- PR metrics pending
Description
## Enhancement
BR needs to use DumpStatsToJSON and LoadStatsFromJSON. But we don't want it to use `handle`, which introduces `domain`.
It's dangerous to use `domain` in BR, since a domain represents a tidb. But it's not a real `tidb` in BR, it may miss some bootstrap operations, and cause bugs.
So it's better to make DumpStatsToJSON and LoadStatsFromJSON as normal functions.
Contributor guide
Assessment
This issue has not been assessed yet.