servenv: provide a global flag for profiling#7496
Merged
systay merged 1 commit intovitessio:masterfrom Feb 18, 2021
Merged
Conversation
Signed-off-by: Vicent Marti <vmg@strn.cat>
sougou
approved these changes
Feb 17, 2021
Contributor
sougou
left a comment
There was a problem hiding this comment.
Very nice! Do you see a case where one may want to profile more than one thing at the same time?
(PR is approved)
Collaborator
Author
I intentionally designed the API so that no more than one profiling mode can be enabled at the same time to prevent contamination/noise. This may have been overly restrictive. I'll revisit the API if we find the the future that running several profiles at once saves us time and doesn't cost accuracy. |
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
The current
servenvpackage provides some knobs to enable some of the profiling options in the Go runtime (but not all of them). In order to fully cover all the use cases that we'll require for profiling Vitess, I've decided to implement an aggregated-pprofflag with a comprehensive syntax, instead adding more one-off flags toservenv. The new flag handles all the existing profile options + all the others that are available in the Go runtime, and allows configuring the output path of the profiles.We're hoping to wire up this new flag to @frouioui's new benchmarking implementation.
Related Issue(s)
Checklist
Deployment Notes
Impacted Areas in Vitess
Components that this PR will affect: