jcoene/statsd-librato — pull request #6 by Nick-Adams-AU (2014-07-16 07:16:23+00:00)
Title: Don't re-use API submission connections

Force the connection to close to prevent the potential re-use of dead connections.

The AWS ELB service used by Librato can sometimes close the TLS connection but not correctly close the HTTP connection. Some versions of Go don't handle this situation correctly:

https://code.google.com/p/go/issues/detail?id=3514

This issue causes the next submission to fail with an EOF error. This change forces every request to close the connection after use to avoid this issue.