Repository navigation
feat(resharding): add validation step for schema_sync - #1692
Merged
Merged
Conversation
Codecov Report❌ Patch coverage is
📢 Thoughts on this report? Let us know! |
meskill
added this pull request to stack #1694
September 29, 2026 14:23
meskill
force-pushed
the
meskill-2026-09-25-feat-resharding---qwpy
branch
from
September 29, 2026 15:02
aeca536 to
0a1be86
Compare
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.
Add a new PostDataValidation phase for schema_sync that allows to run the validation after copying the data. Previously in #1540 the FK constraints where added with
NOT VALIDoption marking the flagconvalidated = falsefor the related table, which disables the check on creation for existing data and maybe disables some optimization that could be done by db for this table.New step runs
VALIDATE CONSTRAINTon this FK to make sure theconvalidatedis set to true on table and the db actually will start to think the values are validated. Like this since it should not block the table from actual writes comparing with creating the FK without options, so we can run this in parallel to our replication process.The check is manual for now and later PRs will use them to run during validation.
For the remainder of the flow:
NOT VALIDsince the copied data could be not in sync because different tables were copied at different snapshot timePostDataValidationcould be run after the replication or after some time during the replication to see if there any errors.