4 ms·
> For long-running, expensive processes that do a lot of waiting, a downside is that if you kill the goroutine, you lose all your work. This is true regardless
by ashishb 1y ago
> For long-running, expensive processes that do a lot of waiting, a downside is that if you kill the goroutine, you lose all your work.
This is true regardless of the language.
I always do a reasonable amount of work (milliseconds to up to a few seconds) worth of work in a Go routine every time. Anything more and your web service is not as stateless as it should be.