How to Stop a Goroutine in Golang
It’s possible to stop a Goroutine by sending a value into it via a signal channel
:
As an alternative, you could also use a WaitGroup
and range
over it:
It’s possible to stop a Goroutine by sending a value into it via a signal channel
:
As an alternative, you could also use a WaitGroup
and range
over it: