-
Notifications
You must be signed in to change notification settings - Fork 4
Description
At the moment, "full identity and hash preservation" can only be demonstrated in Node.js demos using demo scripts (see examples). The same process also works inside the browser with the StorachaTest.svelte component in Svelte, but unfortunately the data is not loading from db after successful restore.
OrbitDB requests the same Manifest CID from the IPFS block storage but cannot locate the restored block (even though it was restored previously). It then queries the IPFS network for it, which fails with the error: "All promises rejected."
This functionality is essential in cases where the entire browser network (Alice, Bob, Peter, etc.) loses all of its data, and someone needs to restore the database one-to-one, including the original Manifest (database address), exact Identity (e.g., DID), and Access Controller (which could be IPFSAccessController, OrbitDBAccessController, or CustomAccessController).
An implemented alternative is to restore the IPFS blocks by analyzing their contents and adding them to a newly created OrbitDB instance using db.put(..restored block data).
An interesting test would be, when a backup was made through the browser code (StorachaTest.svelte), if it could be restored by the NodeJS code example.