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

feat: update to Tokio 0.3 #2317

Closed
wants to merge 36 commits into from
Closed

Conversation

hawkw
Copy link
Contributor

@hawkw hawkw commented Oct 29, 2020

This branch updates Hyper's Tokio dependency to v0.3.x. This continues
the work started by @Urhengulas in PR #2309, updating additional parts
of the codebase and fixing some bugs introduced in that branch.

There are a few important notes:

  • h2 is currently a Git dependency, so this will block releasing a new
    Hyper version until a new h2 is published.

  • Tokio 0.3 doesn't currently have vectored IO APIs, so Hyper has
    (hopefully temporarily) lost its vectored IO support

  • AsyncRead::poll_read_buf and AsyncWrite::poll_write_buf are being
    moved to tokio-util. Currently, they're not available, so we fall
    back to slicing and advancing Bytes and BytesMut buffers
    ourselves. When support lands upstream, we should change back.

  • Ideally, Tokio's new TcpSocket type should gain support for more of
    the socket options hyper needs to set. If this happens, we should be
    able to remove some messy code involving AsRawFd/FromRawFd and
    socket2.

  • This also bumps Hyper's minimum supported Rust version to 1.45.2,
    which is Tokio's minimum supported version. Tokio 0.3 doesn't build
    on 1.39.0

Closes #2309

Signed-off-by: Eliza Weisman [email protected]
Co-authored-by: Urhengulas [email protected]

Urhengulas and others added 28 commits October 24, 2020 17:26
Signed-off-by: Eliza Weisman <[email protected]>
Signed-off-by: Eliza Weisman <[email protected]>
Signed-off-by: Eliza Weisman <[email protected]>
Signed-off-by: Eliza Weisman <[email protected]>
Signed-off-by: Eliza Weisman <[email protected]>
Signed-off-by: Eliza Weisman <[email protected]>
Signed-off-by: Eliza Weisman <[email protected]>
Signed-off-by: Eliza Weisman <[email protected]>
whoopsie!

Signed-off-by: Eliza Weisman <[email protected]>
Signed-off-by: Eliza Weisman <[email protected]>
Copy link
Member

@seanmonstar seanmonstar left a comment

Choose a reason for hiding this comment

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

Some of the benchmarks are still unhappy, they're guarded by the nightly cargo feature.

src/common/drain.rs Outdated Show resolved Hide resolved
hawkw added 4 commits November 4, 2020 14:36
Signed-off-by: Eliza Weisman <[email protected]>
Signed-off-by: Eliza Weisman <[email protected]>
Signed-off-by: Eliza Weisman <[email protected]>
src/server/tcp.rs Outdated Show resolved Hide resolved
@seanmonstar
Copy link
Member

Finished in #2319

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