which internally calls n http services using go-routines, responses from n
http server are written into buffered channel and then main http server
responds back.
The problem I am finding is -
- If MaxIdleConnections per host is low - then each connection after that
limit is not persistent. This results in lot of connections being
established and broken, when the already established connection could have
been reused (I understand that it exceeds the MaxIdleConnections limit).
- If I set MaxIdleConnections to very high number then I may exhaust the
port limit, since n can be high. Creating virtual network interfaces is
option - But I could not find how to bind ip to the http.Client.
I think, may be in highly network intensive tasks, it may be good to not to
immediately close the connections if its above MaxIdleConnections, instead
it should be tried to be reused. May be a basic algo to try to get it to
stable limit and then again close the connections, if they are no longer
needed. Or please suggest if such functionality can be achieved with
current interface.
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.