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
Currently, we send request packet, then receives response packet.
Since Go doesn't provide efficient way to nonblocking EOF check, we may send request packet even if server closed the connection already.
Sending request on already closed connection makes ErrBadConn unsafe. If we can detect EOF before sending packet, we can ErrBadConn safely.
Using separated goroutine to read from connection is Go's normal way for it. Reader goroutine may be required to implement Context support too (#496).
There may be significant performance regression. But I think we should do it.