Skip to content

return ErrClosed if read: connection reset by peer#53

Merged
crosbymichael merged 1 commit intocontainerd:masterfrom
fuweid:me-errclosed-for-read-reset-connection
Oct 23, 2019
Merged

return ErrClosed if read: connection reset by peer#53
crosbymichael merged 1 commit intocontainerd:masterfrom
fuweid:me-errclosed-for-read-reset-connection

Conversation

@fuweid
Copy link
Copy Markdown
Member

@fuweid fuweid commented Oct 21, 2019

When call server.Close(), server will close all listener and notify
flighting-connection to shutdown. Connections are closed asynchronously.
In TestClientEOF, client can send request into closing-connection. But
the read for reply will return error if the closing-connection is
shutdown.

In this case, we should filter error for client side about read: connection reset by peer.

Signed-off-by: Wei Fu [email protected]

When call server.Close(), server will close all listener and notify
flighting-connection to shutdown. Connections are closed asynchronously.
In TestClientEOF, client can send request into closing-connection. But
the read for reply will return error if the closing-connection is
shutdown.

In this case, we should filter error for client side about `read:
connection reset by peer`.

Signed-off-by: Wei Fu <[email protected]>
Copy link
Copy Markdown
Member

@estesp estesp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@crosbymichael
Copy link
Copy Markdown
Member

LGTM

@crosbymichael crosbymichael merged commit 7a6a229 into containerd:master Oct 23, 2019
@fuweid fuweid deleted the me-errclosed-for-read-reset-connection branch October 24, 2019 01:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants