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

Simplify store trait hierarchy #56

Open
rklaehn opened this issue Feb 12, 2025 · 1 comment
Open

Simplify store trait hierarchy #56

rklaehn opened this issue Feb 12, 2025 · 1 comment
Milestone

Comments

@rklaehn
Copy link
Collaborator

rklaehn commented Feb 12, 2025

Idea: make store ops more high level.

Purpose: Then we can afford to box the ops, and we can do a BoxedStore, which in the long term means that the Blobs protocol no longer needs a store type parameter. Also, we might be able to move the LocalPool into the file store.

The downside is that there is less code sharing between the mem and the file store, and writing a primitive mem store becomes more complex because we have to provide high level ops. But I think it is probably worth it just for getting rid of the type parameter.

@rklaehn rklaehn added this to the Blobs 1.0 milestone Feb 12, 2025
@n0bot n0bot bot added this to iroh Feb 12, 2025
@rklaehn rklaehn moved this to 🏗 In progress in iroh Feb 19, 2025
@rklaehn
Copy link
Collaborator Author

rklaehn commented Feb 19, 2025

The current thinking is to get rid of the entire hierarchy and instead do a "protocol" that store implementers have to implement, consisting of the good old low level big enum of commaands with oneshot or mpsc senders for responses...

This will be slightly annoying for store implementers, especially if they don't want to support the full functionality. But it will be much nicer for store users. No more S type parameter everywhere, e.g.

@rklaehn rklaehn removed the status in iroh Mar 10, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: No status
Development

No branches or pull requests

1 participant