elliottt requested wasmtime-core-reviewers for a review on PR #6928.
elliottt requested alexcrichton for a review on PR #6928.
alexcrichton submitted PR review.
alexcrichton created PR review comment:
Could this have a comment explaining why this is doing this?
alexcrichton created PR review comment:
I think this'll want to be the AbortOnDrop handle (or something like that name) Pat recently added too
alexcrichton submitted PR review.
alexcrichton created PR review comment:
Here I'd recommend using
AsyncWriteExt::write_all
since it'll bundle all this internally
alexcrichton created PR review comment:
This'll need some special handling to ensure that if this is cancelled that the task isn't forgotten
elliottt updated PR #6928.
elliottt submitted PR review.
elliottt created PR review comment:
Great point!
elliottt opened PR #6928 from elliottt:trevor/socket-changes
to bytecodealliance:pch/backpressure_2
:
Spawn a task if we can't immediately satisfy a write, storing its join handle for later. Use the presence of the join handle to decide when writes are ready, or if a flush has completed.
<!--
Please make sure you include the following information:
If this work has been discussed elsewhere, please include a link to that
conversation. If it was discussed in an issue, just mention "issue #...".Explain why this change is needed. If the details are in an issue already,
this can be brief.Our development process is documented in the Wasmtime book:
https://docs.wasmtime.dev/contributing-development-process.htmlPlease ensure all communication follows the code of conduct:
https://github.com/bytecodealliance/wasmtime/blob/main/CODE_OF_CONDUCT.md
-->
elliottt submitted PR review.
elliottt created PR review comment:
Ah you're right, I should only clear the option if the write task has finished.
elliottt updated PR #6928.
elliottt updated PR #6928.
elliottt submitted PR review.
alexcrichton created PR review comment:
This may be preexisting, but I think this means that I/O errors turn into trapping errors? Or at least I think that the
Err
here gets turned into a trap, but I could easily be misremembering
elliottt updated PR #6928.
elliottt created PR review comment:
From a DM: we'll have to use
try_write
in a loop as tokio doesn't allowwrite_all
with a non-mutable reference forself
.
pchickey submitted PR review.
pchickey created PR review comment:
The error handling scheme gets fixed in my branch to explicitly call out operation failed vs traps.
elliottt updated PR #6928.
elliottt updated PR #6928.
elliottt updated PR #6928.
elliottt created PR review comment:
I've rebased on Pat's branch, and reworked the error handling to categorize error results as traps or runtime errors.
elliottt submitted PR review.
elliottt merged PR #6928.
Last updated: Nov 22 2024 at 16:03 UTC