-
Notifications
You must be signed in to change notification settings - Fork 261
add pprof options for opm serve command
#968
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
Conversation
Codecov Report
@@ Coverage Diff @@
## master #968 +/- ##
=======================================
Coverage 52.48% 52.48%
=======================================
Files 103 103
Lines 9240 9240
=======================================
Hits 4850 4850
Misses 3468 3468
Partials 922 922 Continue to review full report at Codecov.
|
fb0f968 to
3713770
Compare
|
Should we run a |
I gave this some thought, and based on our current diagnosis needs, I thought offline info would be easier to stick on a bz. Endpoint doesn't seem to capture the |
3713770 to
0ca0a31
Compare
opm serve commandopm serve command
anik120
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/lgtm
exdx
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks really good. We can definitely use a pprof implementation like this in the newer set of APIs.
0ca0a31 to
3fa5a94
Compare
|
/lgtm |
|
Sorry for the driveby, but a potential option for the "where to put the startup profile" is to capture it to a |
3fa5a94 to
3dd5fa7
Compare
tylerslaton
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/lgtm
3dd5fa7 to
9c0209b
Compare
serves cached startup cpu profile data via custom endpoint Signed-off-by: Jordan Keister <jordan@nimblewidget.com>
9c0209b to
c35eb33
Compare
Signed-off-by: Jordan Keister <jordan@nimblewidget.com>
|
I mentioned in slack that I think we can refactor this implementation, but it seems sufficient for now. /lgtm |
Signed-off-by: Jordan Keister <jordan@nimblewidget.com>
|
/lgtm |
awgreene
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Overall this looks great, nice work!
| port string | ||
| terminationLog string | ||
| debug bool | ||
|
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we need this newline?
|
|
||
| // goroutine exits with main | ||
| go func() { | ||
|
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit: remove newline.
|
/lgtm |
dinhxuanvu
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/approve
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: dinhxuanvu, exdx, grokspawn, tylerslaton The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Description of the change:
Add pprof cpu/mem profiling to
opm servecommand.Profiling options including dumping cpu/mem profile files to disk, or serving a /pprof HTTP endpoint. Either/both options can be used.
Usage:
Update the Dockerfile to generate the profiling data (and set optional paths/filenames):
output example:
pprof may be connected to the custom endpoint "/debug/pprof/startup/cpu" like
Motivation for the change:
Downstream issues with FBC serving on alternate architectures, needing more information which could be generally useful.
Reviewer Checklist
/docs