Latest articles
3 articles in the current browsing window, ordered by publication date.
Go 1.27 introduces a goroutine leak profiler that uses a modified garbage collector to identify permanently blocked goroutines on channels and sync primitives in running programs, including production, with minimal overhead and near-zero false positives, demonstrated through real-world examples from CockroachDB, etcd, Kubernetes, and Moby.

This article explains the concept and operation of mutexes, outlines their lock‑unlock workflow, and provides a complete Go example demonstrating how sync.Mutex protects shared data and avoids race conditions in concurrent programs.

The article explains Go's singleton pattern, detailing eager (init) and lazy implementations using sync.Mutex and sync.Once, provides full code examples, demonstrates that each accessor returns the same instance, and discusses trade‑offs between memory usage and performance.

Up to 500 articles, 100 per page. The archive offers another way to explore older articles.