-
Notifications
You must be signed in to change notification settings - Fork 270
wasi-blobstore
draft support
#3060
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
base: main
Are you sure you want to change the base?
Conversation
020f2a8
to
430093e
Compare
Okay there is some silliness going on where it has upgraded an unrelated dependency that now requires Rust 1.83, but that makes one of the examples fling a strange new lint. I'll see if I can roll things back. Faugh. |
ee1a99d
to
2630a65
Compare
crates/factor-blobstore/src/host.rs
Outdated
} | ||
|
||
pub struct BlobStoreDispatch<'a> { | ||
allowed_containers: HashSet<String>, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not entirely sure that it can be but if this can be borrowed it would save a clone
allowed_containers: HashSet<String>, | |
allowed_containers: &'a HashSet<String>, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually if this one works then probably all of the Arc
s below could just be borrows. You'd still need the locks for interior mutability of course.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@lann I tried it and it hasn't segfaulted yet - thanks for the suggestion!
6045e54
to
74449eb
Compare
4bb230c
to
bc914b7
Compare
Signed-off-by: itowlson <[email protected]>
bc914b7
to
fa20d4f
Compare
This is lurching towards readiness, although it still needs a lot of tidying. E.g.
InstanceBuilder::build()
doesn't actually produce a dispatcher object - instead the factor setup does some terrifying shenanigans to try to hook our streams up to Spin's WASI implementation, which means the dispatcher is produced at link time rather than build time.There are some underspecification issues in the current draft of wasi-blobstore: I think I've made my implementations at least consistent, but I probably need to go back over and check that too.
The implementations in this PR are:
I've tested all of them but not tested them hard.
Anyway, I'm sorry this is such a beast and I'm sorry it's still messy - I wanted to do enough to have reasonable confidence in the internal provider API, and I think I'm there bar the renaming and tidying, but it means there's a lot of code, and there's a lot of scar tissue!