-
Notifications
You must be signed in to change notification settings - Fork 5.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
*: use pprof profile to collect CPU time group by SQL and plan digest #24892
Conversation
Signed-off-by: crazycs <chen.two.cs@gmail.com>
Signed-off-by: crazycs <crazycs520@gmail.com>
Signed-off-by: crazycs <crazycs520@gmail.com>
Signed-off-by: crazycs <crazycs520@gmail.com>
Signed-off-by: crazycs <crazycs520@gmail.com>
Signed-off-by: crazycs <crazycs520@gmail.com>
Signed-off-by: crazycs <crazycs520@gmail.com>
Signed-off-by: crazycs <crazycs520@gmail.com>
Signed-off-by: crazycs <crazycs520@gmail.com>
Signed-off-by: crazycs <crazycs520@gmail.com>
Signed-off-by: crazycs <crazycs520@gmail.com>
Signed-off-by: crazycs <crazycs520@gmail.com>
Signed-off-by: crazycs <crazycs520@gmail.com>
Signed-off-by: crazycs <crazycs520@gmail.com>
Signed-off-by: crazycs <crazycs520@gmail.com>
Signed-off-by: crazycs <crazycs520@gmail.com>
/run-all-tests |
Signed-off-by: crazycs <crazycs520@gmail.com>
Signed-off-by: crazycs <crazycs520@gmail.com>
Co-authored-by: Wenxuan <hi@breeswish.org>
Signed-off-by: crazycs <crazycs520@gmail.com>
/run-all-tests |
1 similar comment
/run-all-tests |
/run-all-tests |
/run-common-test |
/run-common-test |
1 similar comment
/run-common-test |
/run-common-test |
/run-common-test tidb-test=master |
No release note, Please follow https://github.com/pingcap/community/blob/master/contributors/release-note-checker.md |
/run-all-tests |
/build |
No release note, Please follow https://github.com/pingcap/community/blob/master/contributors/release-note-checker.md |
/run-check_release_note |
/merge |
This pull request has been accepted and is ready to merge. Commit hash: 75e8d94
|
/merge |
Hi
Thank you for your excellent services!
|
Track issue: #24875
What problem does this PR solve?
This PR uses
pprof profile labels
to collect CPU time group by SQL and plan digest.What is changed and how it works?
The implementation is:
1: Use SQL digest and plan digest as the pprof labels.
There is a special case, for
execute stmt
SQL, should use the prepare SQL digest as thesql_digest
pprof label.Using a buffer channel to avoid parse and output take too much time that infect the fetching profile work.
Other problem
Because the
profile worker
keep callingpprof.StartCPUProfile
to fetch profile data, other place (such pprof profile HTTP API handler) callpprof.StartCPUProfile
will be failed.In order to solve this problem, other place should fetch profile data from
profile worker
instead ofpprof.StartCPUProfile
.Check List
Tests
Side effects
Release note