Skip to content
This repository was archived by the owner on Sep 21, 2024. It is now read-only.

feat!: Disaster recovery via gateway - #637

Merged
cdata merged 1 commit into
mainfrom
feat/c-ffi-recover-sphere
Sep 19, 2023
Merged

feat!: Disaster recovery via gateway#637
cdata merged 1 commit into
mainfrom
feat/c-ffi-recover-sphere

Conversation

@cdata

@cdata cdata commented Sep 18, 2023

Copy link
Copy Markdown
Collaborator

This change proposes a disaster recovery mechanism where an embedding Noosphere client may take advantage of an existing gateway to restore a user's local sphere data.

In order to recover data from a gateway, the following information is needed:

  • URL of the gateway
  • The DID of the user's sphere
  • The name of an authorized device key
  • The user's recovery mnemonic

The Noosphere library then generates an ephemeral, one-time-use authorized credential and uses it to perform the fetch half of a gateway sync. After the sync completes, it ensures that the local storage layer is properly configured to use the original device key.

@jsantell jsantell left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looking forward to this one

Comment thread rust/noosphere-core/src/context/sync/write.rs Outdated
Comment thread rust/noosphere/src/ffi/sphere.rs
Comment thread rust/noosphere/tests/distributed_basic.rs Outdated
Comment thread rust/noosphere/tests/gateway.rs Outdated
Comment thread rust/noosphere-cli/src/native/helpers/workspace.rs
@cdata
cdata force-pushed the feat/c-ffi-recover-sphere branch 7 times, most recently from 56fabc1 to 2e57950 Compare September 19, 2023 18:31
@cdata

cdata commented Sep 19, 2023

Copy link
Copy Markdown
Collaborator Author

Continuing the trend of forcing lint checks for missing documentation on a crate-by-crate basis, I added #[warn(missing_docs)] to the noosphere crate and filled in the gaps where docs were missing.

@cdata
cdata marked this pull request as ready for review September 19, 2023 18:53
@cdata
cdata requested a review from jsantell September 19, 2023 18:53
jsantell
jsantell previously approved these changes Sep 19, 2023
Comment thread rust/noosphere/src/ffi/sphere.rs Outdated
Comment thread rust/noosphere/src/ffi/tracing.rs
Comment thread rust/noosphere/src/platform.rs Outdated
Comment thread rust/noosphere/src/sphere/builder/mod.rs
Comment thread rust/noosphere/src/sphere/builder/recover.rs
Comment thread rust/noosphere/src/sphere/builder/recover.rs
Comment thread rust/noosphere/src/storage.rs Outdated
Comment thread rust/noosphere/tests/gateway.rs
@cdata
cdata force-pushed the feat/c-ffi-recover-sphere branch from bf8579d to ec2f9a4 Compare September 19, 2023 19:49
@cdata
cdata merged commit 70e7331 into main Sep 19, 2023
@cdata
cdata deleted the feat/c-ffi-recover-sphere branch September 19, 2023 19:50
@github-actions github-actions Bot mentioned this pull request Sep 19, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants