-
Notifications
You must be signed in to change notification settings - Fork 1.2k
track: IPFS Repo
#51
Comments
Updated this issue |
Hey @diasdavid. I have some questions about js-ipfs repo init that I could use some clarification on:
Thanks! |
Starting from the bottom:
You can find on the Architecture diagram on the README of js-ipfs-repo that an IPFS repo is constructed by several 'subrepos' or blob-store instances, to enable the user to have a repo running on fs, an in memory db, indexeddb, even a networkDB or mixed :) The benefit of using abstract-blob-store is that paths are handled as keys and the blob store implementation deals with them. An fs-blob-store will deal with the key as a path, an level-blob-store will handle the key as a key. You can find other varieties here https://github.com/maxogden/abstract-blob-store#some-modules-that-use-this In fact, you can see that js-ipfs-repo already has tests that run (with locks included) both in Node.js (with fs-blob-store) and in the browser (with indexedDB-blob-store) https://github.com/ipfs/js-ipfs-repo/tree/master/tests.
repo init needs to ensure that a repo can be mounted with that base path/key and the blob-stores passed (making sure a repo doesn't exist there yet, for example)
I hope this makes it more clear, let me know if there are still questions :) |
That helps, @diasdavid. Doesn't this mean that all of the repo's stores must share the same key? What if that doesn't make sense in all implementations? E.g. I wish to store keys in fs-repo but the rest in index-db. I have to use an FS path like Wouldn't it make more sense to either a) allow each store to specify its own key, or b) just use one store for the whole repo? |
I made it this way because go-ipfs uses |
"repo root" has no meaning in |
Another question! Why should we exposed |
re: |
It would make sense to upgrade https://github.com/ipfs/js-ipfs-repo to be able to tell stats about the repo.
|
IPFS Repo is the storage driver for IPFS.
To learn more about the repo, you can
Implementation Roadmap
jsipfs repo initNot used anymorecorehttp-apicliPinning
#59)The text was updated successfully, but these errors were encountered: