-
Notifications
You must be signed in to change notification settings - Fork 0
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
Handling conflict responses #26
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
The root hash is enough to determine consistency.
So that a client when attempting to patch a remote WAL and getting a CONFLICT response status that includes information that proves that the client root commit is included in the server commit tree (client is behind the remote) then it will pull the remote WAL and attempt to retry applying the patch on top of the earlier changes.
Prepare to mirror in-memory vaults to disc in the shell client.
Improve logic for creating accounts in client CLI.
Prepare for user input when a conflict occurs.
Sketch draft version of a force pull.
Creates backup copies of any existing vault and WAL files, creates an empty new local WAL file, pulls the WAL from the remote server and applies any outstanding changes from the patch file over the top of the new local WAL file and then updates the in-memory version of the vault.
Was commented out to test the conflict handling on the client.
Calling create generated the id and mirroring to disc would generate a different id so added an insert() function and use that in the gatekeeper to ensure identifiers are mirrored correctly.
Integrated with the client force_pull() logic so that it uses a snapshot as a backup for potentially lossy operations.
Do not store an index file use the snapshot modification time as the timestamp instead.
Also update the server backend to use the snapshot manager to create a backup when replacing the contents of a WAL file. Closes #31.
So the new WAL file is pushed to the server.
Wrong OpenType when creating the file stream to update the number of patch events. Closes #32.
Moved the compact command to a subcommand of history and asked for confirmation before compaction. Improvements to the display formatting of Timestamp to support RFC3339 and RFC2822. Implement `history check` to verify the integrity of the current WAL file and `history ls` to list the events in the current WAL. Minor changes to prefer append() to extend_from_slice() where possible. Closes #29.
tmpfs
added a commit
that referenced
this pull request
Jan 28, 2023
* Do not send commit recipts in patch_wal(). The root hash is enough to determine consistency. * Work in progress resolving conflicts. * Run cargo fmt. * Restore the public directory for CI. * Fix commit compare logic. * Support binary encoding for commit proof. * Prepare server for new header encoding. * Prepare new commit proof encoding on server and client. * Debug commit proof logic. * Draft logic for retry on conflict. So that a client when attempting to patch a remote WAL and getting a CONFLICT response status that includes information that proves that the client root commit is included in the server commit tree (client is behind the remote) then it will pull the remote WAL and attempt to retry applying the patch on top of the earlier changes. * Tidy patch conflict handling. * Do not derive in headers. * Support mirror in Gatekeeper. Prepare to mirror in-memory vaults to disc in the shell client. * Improve caching client implementation. * Remove create vault command from client CLI. * Rename the match proof header. * Prepare for vault mirror support. Improve logic for creating accounts in client CLI. * Propagate conflict error. Prepare for user input when a conflict occurs. * Tidy constants handling. * Tidy core module exports. * Remove deprecated passphrase module. * Tidy exports. * Improve conflict handling. Sketch draft version of a force pull. * Prepare for patch file support. * Initial force pull implementation. Creates backup copies of any existing vault and WAL files, creates an empty new local WAL file, pulls the WAL from the remote server and applies any outstanding changes from the patch file over the top of the new local WAL file and then updates the in-memory version of the vault. * Restore soft conflict handling in the server. Was commented out to test the conflict handling on the client. * Fix id problem with vault mirroring. Calling create generated the id and mirroring to disc would generate a different id so added an insert() function and use that in the gatekeeper to ensure identifiers are mirrored correctly. * Fix bug with set command, closes #28. * Draft snapshot implementation. Integrated with the client force_pull() logic so that it uses a snapshot as a backup for potentially lossy operations. * Simplify snapshot manager. Do not store an index file use the snapshot modification time as the timestamp instead. * Move CommitHash type. * Add snapshot commands to the shell client. Also update the server backend to use the snapshot manager to create a backup when replacing the contents of a WAL file. Closes #31. * Prepare for compact shell command. * Fix bugs with patch file implementation. * Improve compact logic. So the new WAL file is pushed to the server. * Fix bad file descriptor error. Wrong OpenType when creating the file stream to update the number of patch events. Closes #32. * Remove obsolete UpdateVault variant. * Update readme. * Updated public files for the server webapp. * Update signature for appending audit logs. * Support history command. Moved the compact command to a subcommand of history and asked for confirmation before compaction. Improvements to the display formatting of Timestamp to support RFC3339 and RFC2822. Implement `history check` to verify the integrity of the current WAL file and `history ls` to list the events in the current WAL. Minor changes to prefer append() to extend_from_slice() where possible. Closes #29. * Use choice for conflict handling.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
To sync client WAL start from the server WAL.