####Invalid connection (unexpected EOF)
This becomes an issue when the server closes an active connection in the Command Phase, because it reached its idle timeout, or because connections are actively being pruned by processes such as pt-kill
理想方式,判断该connection是否可用
check connection health
Each incoming HTTP request provides a Context
object, which becomes canceled if the client disconnects early, and on top of it you can extend your Context
with a deadline.
Returning temporary memory is actually an important optimization, which is explicitly encouraged in the driver contract, and works well in practice for MySQL because it lets us return pointers to the connection buffer where we’re reading results directly from MySQL.