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

reproduction of issue 106: no history available when repo.find() is invoked and the repo has a storage provider #113

Merged
merged 8 commits into from
Jul 4, 2024

Conversation

heckj
Copy link
Collaborator

@heckj heckj commented Jul 3, 2024

resolves #106

  • adds additional integration tests

  • changes repo logic to initiate sync on document creation (calls to any of import, create, or clone)

  • fixes internal mismatch logic that falsely reported a document was in the storage provider, when it wasn't actually available, causing it to never be requested from external peers.

  • in the scenario where a document is sync'd on createion, and a peer is connected, the other peer will have a record of the document to return an immediate result on find(), but the contents won't be completely up to date until the sync has processed. The updated tests (unit and integration) verify that a sync happens, but there's no clear indicator of "I'm up to date with all my peers" right now. Additional features: gossiping the 'heads' of peers for documents in question, or a change to the sync protocol to return an "ack, up to date" to get an RPC like mechanism is needed to enable that.

@heckj heckj merged commit c3211ed into main Jul 4, 2024
1 check passed
@heckj heckj deleted the issue106 branch July 4, 2024 00:29
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.

Document added to repo doesn't seem to get state from web socket peer until it sends state of own
1 participant