Limit the number of goroutine while using errgroup

110 views
Skip to first unread message

Reach John

unread,
Nov 5, 2021, 12:37:02 PM11/5/21
to golang-nuts
How to control the number of goroutines when using errgroup? Is there a best practice?

Sebastien Binet

unread,
Nov 5, 2021, 12:51:13 PM11/5/21
to Reach John, golang-nuts
One can use errgroup.Group in conjunction with x/sync/semaphore.

-s

Nov 5, 2021 17:36:56 Reach John <solita...@gmail.com>:

How to control the number of goroutines when using errgroup? Is there a best practice?

--
You received this message because you are subscribed to the Google Groups "golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/golang-nuts/3920c043-787e-439b-b92a-fdbf29555571n%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages