User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/76.0.3809.132 Safari/537.36
When using TRACE <query> a user expects to see the trace for that specific query.
Instead, the output includes traces all active sessions at that moment. That is highly confusing and has possible privacy/security issues.
Steps to Reproduce:
(shell 1)$ yes "SELECT 'I am from session 1';" | mclient -f trash -d demo
(shell 2)$ yes "SELECT 'I am from session 2';" | mclient -f trash -d demo
(shell 3)$ echo "TRACE SELECT 'I am from session 3';" | mclient -d demo
Repeat command from shell 3. Every time it gives a different output, with content from the other sessions.
Returning global TRACE information as part of the result set is likely to be abandoned soon. The purpose of it was to get a complete picture on what is going on in the server. Because, the performance of a single query may be affected by concurrent queries.
Indeed, an overview of all activities may disclose more information then required.
With the latest changes on default branch, this should no longer be an issue.
The Default branch contains better code to separate the profiler events