Hi Brian, I can see the same behavior.
Make a custom http.Transport for your http.Client, and set
MaxIdleConnsPerHost to 50 (something >= the number of concurrent
connections you wish to make.) The default Transport will close many
connections (over the default limit of 2) during the brief time they
are idle after the response body is closed but before another
goroutine makes a request.
Cheers,
Caleb
> --
> 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.
> For more options, visit
https://groups.google.com/d/optout.