Re:What could Go wrong with a mutex
by gnfargbl on Wednesday November 03, 2021 @06:38AM
(#29092918)
One way I often debug this kind of problem is to use go's built-in pprof tooling. You can insert a profiling server into your program in four lines: https://pkg.go.dev/net/http/pprof. Then, do something like
to get a goroutine profile of your running program, and use the web command to display it in a browser as a DAG. The stuck goroutine can usually be seen pretty easily on the graph.
[ Parent
| on HN ]
There are no comments on this comment yet.