-
Notifications
You must be signed in to change notification settings - Fork 3.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
64137: sql: add 'max sql temp disk usage' stat to explain analyze output r=cucaroach a=cucaroach ``` sql: add 'max sql temp disk usage' stat to explain analyze output Disk usage is currently tracked per node but we don't report it. Having to look at the sql.disk.distsql.spilled.bytes.written metric or examine explain analyze (distsql) diagram is cumbersome. Example: > explain analyze (distsql) SELECT ... planning time: 2ms execution time: 18.6s distribution: full vectorized: true rows read from KV: 6,001,215 (806 MiB) cumulative time spent in KV: 10.8s maximum memory usage: 32 MiB network usage: 0 B (0 messages) max sql temp disk usage: 170 MiB Add a unit test to confirm output is as expected and doesn't appear in non-spill situations. Also this field is completely omitted in redact situations as whether we spill is a metamorphic random variable so spilling isn't deterministic. Release note (sql): Add line to explain analyze output to show disk spill usage to make it clear when disk spilling occurs executing a query. This output is only shown when the disk usage is greater than zeor. The verbiage in the distsql explain diagrams changed from 'max scratch disk allocated' to 'max sql temp disk usage' for consistency and too match how we talk about sql spill disk usage elsewhere. ``` fixes #64111 Co-authored-by: Tommy Reilly <[email protected]>
- Loading branch information
Showing
11 changed files
with
112 additions
and
14 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.