Repository navigation
Conversation
apache#15454 stopped re-validating spill files on read. apache#21882 moved the reader to `StreamDecoder`, whose `with_skip_validation` only applies to dictionary batches, so every offset and string of a spilled record batch is validated again. Decode the framed messages with `RecordBatchDecoder` instead, which honors the flag.
Contributor
Author
|
Related PR apache/arrow-rs#11552 |
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.
Which issue does this PR close?
Rationale for this change
Since 55.0.0, reading a spill file validates every record batch again, including a UTF-8 check of every string. #15454 had turned that off, but
StreamDecoder::with_skip_validation, which #21882 switched to, only applies to dictionary batches.What changes are included in this PR?
SpillReaderStreamalready frames whole IPC messages. It now decodes them withRecordBatchDecoderandread_dictionary_impl, which take theskip_validationflag, instead ofStreamDecoder.spill_iobenchmark, criterion medians averaged over two alternating runs:spill_io/StreamReader/read_100spill_compression/q16/uncompressedspill_compression/wide/uncompressedspill_compression/q16/lz4_framespill_compression/q16/zstdq2andq20have no strings and stay within noise.What is the testing strategy for this PR?
test_spill_read_skips_validationspills aUtf8value that is not UTF-8. It fails on main withInvalid UTF8 sequence at string index 0and passes here. The existing spill tests cover decoding, including dictionaries and truncated files.Are there any user-facing changes?
No.