EPISODE · Nov 30, 2022 · 14 MIN
013: Go's concurrency to the rescue
from go podcast() · host Dominic St-Pierre
Go's worker queue pattern:type WorderPool struct { queue chan int}func (wp *WorkerPool) start() { for i := 0; i < 500; i++ { go funcIO { for id := range wp.queue { doSomething(id) } }() }}func (wp *WorkerPool) add(id int) { wp.queue <- id}Go 1.20 errors.Join / multiple unwrap errorMy course: Build SaaS apps in GoBest way to show support for the pod is by sharing it around and buying my course.
Embed this episode
What this episode covers
Real-world story about how Go's concurrency save a .NET performance issue I was having where I needed to call a process that takes 5 to 15 seconds to complete 6m times.
Ready to play
013: Go's concurrency to the rescue
No transcript for this episode yet
Similar Episodes
No similar episodes found.
Similar Podcasts
No similar podcasts found.