Skip to content

Draft: Make documents and user identity presistent between app starts#69

Closed
jsparber wants to merge 12 commits into
mainfrom
jsparber/presistent_store
Closed

Draft: Make documents and user identity presistent between app starts#69
jsparber wants to merge 12 commits into
mainfrom
jsparber/presistent_store

Conversation

@jsparber
Copy link
Copy Markdown
Collaborator

This is based on #65 and #67

@adzialocha adzialocha changed the base branch from main to jsparber/add_connection_popover April 24, 2025 15:30
@jsparber jsparber force-pushed the jsparber/add_connection_popover branch from 392ee8c to 2934e1c Compare April 25, 2025 14:45
@jsparber jsparber changed the base branch from jsparber/add_connection_popover to main April 25, 2025 14:49
@jsparber jsparber force-pushed the jsparber/presistent_store branch 3 times, most recently from ff8cd00 to a53647f Compare April 26, 2025 14:07
@jsparber
Copy link
Copy Markdown
Collaborator Author

I'm seeing a couple of the following errors:

2025-04-26T14:24:31.998642Z ERROR aardvark_node::network: ingesting operation failed: critical storage failure: an error occurred with the sqlite database: error returned from database: (code: 1555) UNIQUE constraint failed: operations_v1.hash

@jsparber jsparber force-pushed the jsparber/presistent_store branch 3 times, most recently from 6179910 to 0cd1f75 Compare May 5, 2025 11:01
jsparber added 12 commits May 5, 2025 13:01
This ensures that operations are blocked and stored till the node is
running. They will be executed in call order once the node is running.
This probably doesn't fully unsubscribe since p2panda doesn't really
implement it, but at least we don't store any updates to the
OperationStore.
See for more details: p2panda/p2panda#639
This includes:
    - subscribe/unsubscribe from p2panda network
    - document name
    - last accessed
This exposes the PublicKey and PrivateKey structs via boxed glib types
so they can be used as GObject properties.
This uses oo7 to store the private key ("identity") to the keyring.
The node does only store the OperationStore for now and doesn't reload
operations.
Logically it makes sense that we map documents to a set of authors
instead of the other way around. Additionally this makes the
implementation of TopicLogMap trait much simpler without the need to
look at authors that aren't authors of a specific document.
@jsparber jsparber force-pushed the jsparber/presistent_store branch from 0cd1f75 to 0db0aad Compare May 5, 2025 11:01
@jsparber
Copy link
Copy Markdown
Collaborator Author

jsparber commented May 7, 2025

close in favor of #75

@jsparber jsparber closed this May 7, 2025
@adzialocha adzialocha deleted the jsparber/presistent_store branch May 26, 2025 09:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant