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

pd: use tokio_util::sync::PollSender in consensus svc #436

Merged
merged 1 commit into from
Mar 2, 2022

Commits on Feb 15, 2022

  1. pd: use tokio_util::sync::PollSender in consensus svc

    In v0.7 of `tokio-util`, the `PollSender` API was changed to have the
    semantics that most users expect (see tokio-rs/tokio#4214). The
    `poll_send_done` method was replaced with a `poll_reserve` method, and
    the implementation rewritten to drive a `Sender::reserve_owned` future
    that's consumed in `send_item`. Now, `PollSender` essentially implements
    exactly the same code that was written by hand in the consensus service.
    We can simplify the consensus service significantly by upgrading the
    `tokio-util` dependency to 0.7 and replacing the hand-written version
    with `PollSender`.
    
    There should be no functional change as a result of this refactor.
    hawkw committed Feb 15, 2022
    Configuration menu
    Copy the full SHA
    52c7216 View commit details
    Browse the repository at this point in the history