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

Upgrade to mio 0.8 #326

Merged
merged 1 commit into from
Sep 10, 2023
Merged

Upgrade to mio 0.8 #326

merged 1 commit into from
Sep 10, 2023

Conversation

mrobinson
Copy link
Member

This change upgrades mio for non-MacOS / non-Android unix platforms.
mio is used an abstraction layer over the various methods of doing
epoll, etc on Unix platforms.

There are a few notable changes this upgrade deals with:

  • mio no longer supports level-triggered events. What this means is
    that instead of always delivering readable events for file
    descriptors when there is data left to read, an event is only
    delivered the first time new data becomes available. The consumer is
    expected to try to read from descriptor until it would block. This
    means we have to put a loop around calls to recv for each file
    descriptor. Note that this might change the order that messages
    arrive, since before each polling operation would only give one
    message per fd. Now all available messages are delivered per call to
    poll.
  • The mio API has changed a bit. Now there's a poll registry and also
    Ready has been replaced by Interest.

This change upgrades `mio` for non-MacOS / non-Android unix platforms.
`mio` is used an abstraction layer over the various methods of doing
`epoll`, etc on Unix platforms.

There are a few notable changes this upgrade deals with:

- `mio` no longer supports level-triggered events. What this means is
  that instead of always delivering readable events for file
  descriptors when there is data left to read, an event is only
  delivered the first time new data becomes available. The consumer is
  expected to try to read from descriptor until it would block. This
  means we have to put a loop around calls to recv for each file
  descriptor. Note that this might change the order that messages
  arrive, since before each polling operation would only give one
  message per fd. Now all available messages are delivered per call to
  poll.
- The `mio` API has changed a bit. Now there's a poll registry and also
  `Ready` has been replaced by `Interest`.
@jdm jdm added this pull request to the merge queue Sep 10, 2023
Merged via the queue into master with commit e0af749 Sep 10, 2023
12 checks passed
@atouchet atouchet mentioned this pull request Sep 22, 2023
@mrobinson mrobinson deleted the mio-0.8 branch November 15, 2023 11:14
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.

2 participants