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

Implement Async IO Select Hostcalls #188

Merged
merged 5 commits into from Nov 16, 2022
Merged

Commits on Nov 16, 2022

  1. Implement Async IO Select Hostcalls in Viceroy

    This commit adds the fastly_async_io hostcalls `select` and `is_ready`
    to Viceroy. Up to this point we only would do `select` for things like
    `PendingRequest`. Now we abstract over an `AsyncItem` which could be a
    `PendingRequest`, `StreamingBody`, or `Body` and you can call `select`
    over any of these async io operations. Most of this code is to
    accomodate these changes while maintaining the behavior of `select` for
    `PendingRequest` utilizing these new calls and creating the `AsyncItem`
    enum to hold all of these differing types in the same `async_item` map.
    
    We also add an integration test similar to the C@E platform's to make
    sure that we implement the behavior correctly. With this we can be
    confident that select works the way we intend it too! As a bonus side
    effect of these changes we also add async support for hosts in our
    testing code in Viceroy which gives us some more flexibility in what we
    can accomplish or use!
    mgattozzi committed Nov 16, 2022
    Copy the full SHA
    c4241f3 View commit details
    Browse the repository at this point in the history
  2. Avoid double-close in async IO test

    aturon authored and mgattozzi committed Nov 16, 2022
    Copy the full SHA
    c63c5b3 View commit details
    Browse the repository at this point in the history
  3. Copy the full SHA
    4843a1c View commit details
    Browse the repository at this point in the history
  4. Copy the full SHA
    3c9e62b View commit details
    Browse the repository at this point in the history
  5. Refine comment of async_io test

    This change refines the comment on why we've cfged out a test on windows with a link to the issue tracker for those curious as to why this is the case.
    
    Co-authored-by: Aaron Turon <aturon@fastly.com>
    mgattozzi and aturon committed Nov 16, 2022
    Copy the full SHA
    12ec538 View commit details
    Browse the repository at this point in the history