Avoiding Data Races in Go: Best Practices for Concurrency
8 min readSep 5, 2022
--
Concurrency is such a foundational capability of the Go language that it is effortless to write code that leverages multiple goroutines, sometimes without even knowing.
As an example, if you’ve ever used the net/http
package to create a web service, you’ve used goroutines.