You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I started a golang-nuts thread for this (http://goo.gl/D7Gvt) but never got a
response for my final question.
Calling `http.Get` or `http.Do` without changing any of the default settings
uses keep-alive connections; you can verify this by running the program Russ
posted in the thread I linked above. However, the docs say this:
> DefaultTransport is the default implementation of Transport and is
> used by DefaultClient. It establishes a new network connection for
> each call to Do [...].
This seems incorrect, unless I'm misreading it. Re-using a cached keep-alive
connection means that a new network connection is *not* established for each
call to `Do`, right?
The docs for the `Transport` type agree with the actual behavior, implying
that its zero value will use keep-alive connections (due to a zero value for
`MaxIdleConnsPerHost` implying `DefaultMaxIdleConnsPerHost`, which is two).
The text was updated successfully, but these errors were encountered:
by jacobsa@google.com:
The text was updated successfully, but these errors were encountered: