-
Notifications
You must be signed in to change notification settings - Fork 612
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
Add Node support #8
Comments
Found this project, seems promising, but this is for heap profiling: |
~0x seems promising for CPU profiling https://github.com/davidmarkclements/0x ~ But the problem is it does the whole process from start to finish, no way to do 10 second intervals. |
This is promising https://github.com/google/pprof-nodejs |
@petethepig I've wrote some kind of wrapper around nodejs profiling in 2019, you can find them there: cpu and heap. Now that i re-read them i find them pretty ugly but it works quite well (i've been using in prod since). I tried to document as much as i could back then inside both package's readme, however there are still few things worth to know:
Generally you'll find some historic in the nodejs's diag working group: nodejs/diagnostics#148 nodejs/diagnostics#444 nodejs/diagnostics#150 Feel free to reach out (mail in bio) if you have any questions Edit: Congrats on the launch on HN btw :) |
Also not directly related to NodeJS but you might find this interesting for browser profiling: https://wicg.github.io/js-self-profiling/ |
I don't understand why you would need to profile v8 for nodejs. that's like profiling CPython compared to simply python as you already did. let v8 devs take care of v8, they have their tools. now for nodejs, you can hook require, this will allow you to modify any local or global module, maybe look at istanbul instrumentor on npm. you could just hook everything and only profile if delta time is over 0.01s. |
I had an issue with v8 deoptimization that pushed one of my app CPU usage to >80% (vs 40% baseline). You can also have C++ dependencies (like grpc) that won't be profiled.
I would suggest to lookup performance for this, this is highly ineficient and block the main thread (so it slow your app), the v8 profiler is using a seperate thread. |
Some time ago I did a summary on NodeJS profilers: https://github.com/slonka/nodejs-production-ready-profiling - things might be outdated but you might find some useful info there. |
Added support for node! Let us know if you have any feedback! |
Feedback: I don't think it's usable, which is probably why it's not a very popular package. @Rperry2174, although Node support is added, Node 18 LTS as of 2022-10 is still not supported. pyroscope-nodejs relies on pprof, which only supports Node 10, 12 or 14. I can see that pyroscope-nodejs is moving to use It would be great to have support for Node 18 to make it usable. |
* print query applications error * order application services by updatedAt desc
TODO
The text was updated successfully, but these errors were encountered: