Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TCP listener isn't closed in Tokio 0.2 on Windows #606

Open
Xanewok opened this issue Jan 5, 2021 · 0 comments
Open

TCP listener isn't closed in Tokio 0.2 on Windows #606

Xanewok opened this issue Jan 5, 2021 · 0 comments

Comments

@Xanewok
Copy link
Contributor

Xanewok commented Jan 5, 2021

When migrating to Tokio 0.2 (in #603) we encountered an issue where the underlying OS socket wasn't closed on Windows (using mio v0.6) when shutting down Hyper server.

Because of this, the OS socket left open performs the TCP handshake but is incapable of doing any progress since the server has already quit. If a client attempts to connect, the connection itself will succeed but any further attempts to progress will block in mio.

For now, we explicitly close the OS socket when the Hyper server has quit but we would like to remove the workaround once we migrate to Tokio 1.0 (which has Windows backend overhauled in its mio v0.7 dependency).

Ref: #603 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant