feat(replication): add support for replica identity full#952
Merged
Conversation
fix issues with replica identity
Codecov Report❌ Patch coverage is 📢 Thoughts on this report? Let us know! |
This comment has been minimized.
This comment has been minimized.
levkk
reviewed
May 1, 2026
| validation_errors.sort_by_key(|e| match e { | ||
| TableValidationError::NoIdentityColumns(table) => table.name.clone(), | ||
| }); | ||
| validation_errors.sort_by_key(|e| e.table.name.clone()); |
Collaborator
There was a problem hiding this comment.
nit: could sort by schema and table name so errors for the same schema appear next to each other.
levkk
reviewed
May 1, 2026
|
|
||
| /// Returns `true` when the named table has at least one unique index that is | ||
| /// fully built and valid on the given server connection. | ||
| pub async fn has_unique_index( |
Collaborator
There was a problem hiding this comment.
For schemas that have 1000s of tables, this could be slow. Try maybe returning a map like this:
| schema | table | unique_index |
|---|---|---|
public |
users |
t |
orders |
items |
f |
levkk
reviewed
May 1, 2026
levkk
reviewed
May 1, 2026
| .cloned() | ||
| .collect(); | ||
| for table in &omni_full { | ||
| self.validate_full_identity_omni_has_unique_index(table) |
Collaborator
There was a problem hiding this comment.
nit: this should be executed as one query, ideally, although probably not critical since this runs only once.
levkk
approved these changes
May 1, 2026
Contributor
Author
|
made a small update to remove some errors that actually shouldn't have been there for identity full and they should not block the execution flow. |
This file contains hidden or 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
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.
Fixes #930