Try out OpenResty XRay for free: https://openresty.com/en/xray/
In this tutorial, you will get a step-by-step tour of how to use OpenResty XRay to quickly pinpoint the blocking or sleeping Go code paths. These code paths may slow down your processes and prevent them from using the full CPU resource.
Text version of this tutorial: https://blog.openresty.com/en/go-low-...
OpenResty XRay is a dynamic-tracing product that automatically analyzes your running applications to troubleshoot performance problems, behavioral issues, and security vulnerabilities with actionable suggestions.
Under the hood, OpenResty XRay is powered by our Y language, targeting various runtimes like Stap+, eBPF+, GDB, and ODB, depending on the context.
OpenResty XRay is a truly non-intrusive dynamic analysis, which does not require installing any special modules or plugins in the target application, does not require recompiling the target application, and does not even require restarting the running process.
Music: https://www.bensound.com
0:00 Problem: low CPU usage
0:55 Spot the blocking Go code paths
2:14 details of analysis report
4:47 Insight page and guided analysis feature