-
Notifications
You must be signed in to change notification settings - Fork 165
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
refactor(iroh-bytes)!: remove flume dependency #2622
Conversation
now that we have eliminated recv_timeout
we still have a dep via quic-rpc though...
Documentation for this PR has been generated and is available at: https://n0-computer.github.io/iroh/pr/2622/docs/iroh/ Last updated: 2024-08-14T07:58:04Z |
7654a88
to
e815643
Compare
@Frando this is similar to what you did with the docs store, I guess. The only difference is that I am using the main runtime to block on so you get the main blocking pool when calling spawn_blocking instead of the (single?) io thread of a single threaded runtime... |
…#2688) ## Description This fixes a small copy and paste bug that was introduced in #2622, here: https://github.com/n0-computer/iroh/pull/2622/files?diff=unified&w=0#diff-bbe46ca272a808bb1c94619ab3264586a47a6ec6e0f7cd5a63dba5e99099241bL1521-R1526 (You need to load the diff for the `fs.rs` file) <!-- A summary of what this pull request achieves and a rough list of changes. --> ## Breaking Changes <!-- Optional, if there are any breaking changes document them, including how to migrate older code. --> None ## Notes & open questions <!-- Any notes, remarks or open questions you have to make about the PR. --> Tests would be nice, but I'm looking at other things right now, so I'd prefer to merge this first :S ## Change checklist - [x] Self-review. - ~~[ ] Documentation updates following the [style guide](https://rust-lang.github.io/rfcs/1574-more-api-documentation-conventions.html#appendix-a-full-conventions-text), if relevant.~~ - ~~[ ] Tests if relevant.~~ - [x] All breaking changes documented.
## Description This is mostly a pretty mechanical replacement of flume with async_channel in the rebd blob store. One not so tiny change is that to support closing a read or write transaction after some delay, and because async_channel does not have recv_timeout, we switch the entire actor loop to run *async* but on a dedicated thread of the main runtime. That way we can use `tokio::select! {..., timeout}` ## Breaking Changes FlumeProgressSender was removed ## Notes & open questions ## Change checklist - [ ] Self-review. - [ ] Documentation updates following the [style guide](https://rust-lang.github.io/rfcs/1574-more-api-documentation-conventions.html#appendix-a-full-conventions-text), if relevant. - [ ] Tests if relevant. - [ ] All breaking changes documented.
Description
This is mostly a pretty mechanical replacement of flume with async_channel in the rebd blob store.
One not so tiny change is that to support closing a read or write transaction after some delay, and because async_channel does not have recv_timeout, we switch the entire actor loop to run async but on a dedicated thread of the main runtime.
That way we can use
tokio::select! {..., timeout}
Breaking Changes
FlumeProgressSender was removed
Notes & open questions
Change checklist