[server][dvc] add table format info in the blob transfer #1428
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.
[server][dvc] add table format info in the blob transfer
There is an edge case where multiple file formats may coexist within a single cluster. For instance, DVC1 might use a plain-table format while DVC2 uses a block-based format. If DVC2 requests data from DVC1 during bootstrap, it could end up with a plain-table store in DVC2, leading to read issues.
This PR addresses the issue by:
Receiver side: Including the table format in the bootstrap request URI. An example URI:
[0]""/[1]"store"/[2]"version"/[3]"partition/[4]"table format"
.Sender side: Storing the current snapshot format in the snapshot manager. When a bootstrap request arrives, the snapshot manager compares the existing snapshot format with the requested table format. If they do not match, it returns a 404 error to reject the blob transfer request.
How was this PR tested?
Integration test "testBlobTransferThrowExceptionIfTableFormatNotMatch".
Does this PR introduce any user-facing changes?