Track the memory usage of Runtime Info #44047
Labels
affects-6.5
This bug affects the 6.5.x(LTS) versions.
affects-7.1
This bug affects the 7.1.x(LTS) versions.
report/customer
Customers have encountered this bug.
sig/execution
SIG execution
type/enhancement
The issue or PR belongs to an enhancement.
Enhancement
Now tidb will save an ExecDetails for each request, and will not release the memory until the end of the SQL. In generally, the number of requests that need to be sent by a SQL is not very large, so this part of the memory will not be very large. But in some extreme scenarios, when the number of requests reaches 10 million, the memory usage of this part will reach more than GB. This may cause frequent GC, CPU usage and memory usage. Therefore, this part of memory also needs to be tracked in order to intervene in extreme scenarios.
For example,
Reproduce Steps
One SQL will send 12 million request and the runtime info will occury 1GB memory.
The text was updated successfully, but these errors were encountered: