Radar · Go · Archive · Week 36 · Aug 31 – Sep 6, 2026
Goroutine Leak Profiles
Worth knowingstdlib
- What changed
- Go 1.27 includes new goroutine leak profiles.
- Production impact
- The source does not say.
- Try it
- Run
go test -run TestLeak -benchmem -bench .on a program that intentionally leaks goroutines and observe the new profile output. - Source
- go.dev/blog/goroutine-leak-profiles
Understand it, then run it
Go 1.27 adds a new way to spot goroutine leaks in a running program. A goroutine leak happens when a goroutine blocks forever and the program can never unblock it. The new *goroutineleak* profile can be collected through the normal pprof HTTP endpoint, just like the usual goroutine profile. When you fetch that profile, it lists the goroutines that are permanently blocked on channels or sync primitives, making it easy to see where a leak is happening.
Written by gpt-oss-20b from the linked source · claims checked against the sources · archive, not individually reviewed