Skip to content

Add new debug handlers to set block and mutex profiling#6137

Merged
sougou merged 4 commits intovitessio:masterfrom
planetscale:jacques_blockmutex_profiling
May 11, 2020
Merged

Add new debug handlers to set block and mutex profiling#6137
sougou merged 4 commits intovitessio:masterfrom
planetscale:jacques_blockmutex_profiling

Conversation

@aquarapid
Copy link
Copy Markdown
Contributor

@aquarapid aquarapid commented May 1, 2020

So that actually useful pprof for block and mutex can be extracted from a
running vtgate.

Use this by calling something like http://localhost:15001/debug/blockprofilerate?rate=1 (for 100% blocking coverage) and http://localhost:15001/debug/mutexprofilefraction?fraction=1 (for 100% mutex coverage)

Signed-off-by: Jacques Grove aquarapid@gmail.com

EDIT: The final implementation supports this for all vitess binaries.

that actually useful pprof for block and mutex can be extracted from a
running vtgate.

Signed-off-by: Jacques Grove <aquarapid@gmail.com>
@aquarapid aquarapid requested a review from sougou as a code owner May 1, 2020 02:03
Copy link
Copy Markdown
Contributor

@sougou sougou left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you move this to servenv/status.go? Then you can add a link to these URLs here: https://github.com/vitessio/vitess/blob/master/go/vt/servenv/status.go#L110-L111, and also default them to 100% coverage. This will benefit all our binaries.

If it gets too complicated, let me know, we can push this through and move it later.

sougou and others added 3 commits May 2, 2020 10:47
This will allow us to debug all vitess servers.

Signed-off-by: Sugu Sougoumarane <ssougou@gmail.com>
Signed-off-by: Sugu Sougoumarane <ssougou@gmail.com>
UI, we should make it toggles, and mark it
appropriately to alert users to the fact
that it can be dangerous from a performance
impact p.o.v.

Signed-off-by: Jacques Grove <aquarapid@gmail.com>
@sougou sougou merged commit 63c4ceb into vitessio:master May 11, 2020
@sougou sougou deleted the jacques_blockmutex_profiling branch May 11, 2020 22:33
@deepthi deepthi changed the title Add new debug handlers to set block and mutex profiling in vtgate, so Add new debug handlers to set block and mutex profiling Jul 18, 2020
@deepthi deepthi added this to the v7.0 milestone Jul 27, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants