Skip to content

Commit

Permalink
fix: ignore conn read timeout
Browse files Browse the repository at this point in the history
  • Loading branch information
twz915 committed Dec 6, 2023
1 parent d7253f4 commit 12adf60
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions internal/remote/remote_client.go
Original file line number Diff line number Diff line change
Expand Up @@ -180,11 +180,11 @@ func (c *remotingClient) receiveResponse(r *tcpConnWrapper) {
return
}
// ignore name server connection read timeout
var isTimeout bool
if netErr, ok := err.(net.Error); ok && netErr.Timeout() {
isTimeout = true
}
if err != io.EOF && !isTimeout {
rlog.Debug("conn error, close connection", map[string]interface{}{
rlog.LogKeyUnderlayError: err,
})
} else if err != io.EOF {
rlog.Error("conn error, close connection", map[string]interface{}{
rlog.LogKeyUnderlayError: err,
})
Expand Down

0 comments on commit 12adf60

Please sign in to comment.