wetware / pkg

Peer-to-peer cloud environment
https://wetware.run
Other
38 stars 7 forks source link

Add schema and generated types for anchor cells. #124

Closed lthibault closed 1 year ago

lthibault commented 1 year ago

This PR is the first part of an effort to extend #108 (basic Anchor implementation) with the ability to load/store values from an anchor path. It may be helpful for reviewers to quickly re-read #108.

The present PR adds a cell() method to the Anchor schema. This method returns a set of capabilities that serve as an access-controlled interface to the values stored in an anchor. I recommend reading the docstrings in anchor.capnp, and encourage reviewers to flag any lingering uncertainties.

The next PR will focus on the actual implementation of the cell interfaces, as well as updating the Anchor's refcounting logic to track the presence of stored values.

@mikelsr I'm tagging you as the primary reviewer as per our conversation on Friday. This will hopefully help you form an understanding of the anchor API, and inform our future work on Wetware demos.

cc @aratz-lasa @ayazabbas Your feedback is, as always, most welcome :)

lthibault commented 1 year ago

@mikelsr Note that for simplicity's sake, I am opening this PR against the master branch, so we'll likely want to rebase v0.1.0 against master at some point. No need to do it right now, though, especially since I expect to put in a small clean-up effort before we merge.

mikelsr commented 1 year ago

Thanks for the changes :)