In the document “Online Modify TiDB Configuration”, is the description that log.expensive-threshold corresponds to the system variable tidb_expensive_query_time_threshold inaccurate?
The document describes that when the number of query rows exceeds log.expensive-threshold, the [EXPENSIVE_QUERY] log will be recorded. However, according to feedback from multiple TiDB users, this configuration parameter does not work. Only when mem-quota-query (tidb_mem_quota_query) or tidb_expensive_query_time_threshold is triggered, the [EXPENSIVE_QUERY] log will be recorded.
Could the official team please confirm the above two questions?
The log.expensive-threshold parameter no longer works in the new version.
Before the changes in this PR, log.expensive-threshold would log [EXPENSIVE_QUERY] if the optimizer phase determined that the result rows might exceed 1000.
After the changes, this behavior was mistakenly removed. The corresponding documentation was not updated in time, so currently, the log.expensive-threshold configuration is useless.
In the section, it should also be a documentation error; log.expensive-threshold does not correspond to tidb_expensive_query_time_threshold.