Disk spill is better placed in actionMuForSoftLimit than actionMuForHardLimit
Open
type/enhancement
- Dominant language
- Go
- Stars
- 40.5k
- Forks
- 6.2k
- PR merge metrics
- PR metrics pending
Description
## Enhancement
The action (distsplillaction sortspillaction) in {{actionMuForHardLimit}}. I think it would be better to put it in {{actionMuForSoftLimit}}. This way, assuming the statement quota memory limit is 1GB, I can set it to trigger disk spill when 50% of the statement memory limit is reached. And the softlimit ratio (default: 0.8) can be set by the user.
https://github.com/pingcap/tidb/blob/accff686216c62c8a1f7bdb597141e666e3f2bde/util/memory/tracker.go#L68
Contributor guide
Assessment
This issue has not been assessed yet.