Repository navigation
Conversation
A PlanDataSource scan had one partition, so engines that parallelise by partition read a whole file on one worker. Unordered, unlimited scans now split the row range into near-equal partitions, sized by the new ScanRequest::target_partitions hint or the available parallelism, with at most one partition per started 65,536 rows. DataFusion passes its target partition count. Signed-off-by: Nicholas Gates <nick@nickgates.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Nicholas Gates <nick@nickgates.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
A single file scanned through the Scan API ran as one partition, so DataFusion's
VortexTablespread a one-file table over one output partition.PlanDataSourcenow splits an unordered, unlimited scan into contiguous row ranges, and the newScanRequest::target_partitionslets the engine say how many it wants instead of the source guessing; DataFusion passes its target partitions, JNI and the C API passNone, which keeps the available-parallelism default.Because the split count now depends on the request, split numbers cannot be stable partition indices, which the
DataSourcedocs promise. A partition's index now names the unit of the source it reads (aPlanDataSourceis one unit, index 0),partition_range/partition_selectionselect units, and the docs say thatrow_rangeandselectionare in each unit's own row numbering and apply once across a unit's partitions.Breaking:
ScanRequesthas a new public field, so struct literals without..Default::default()must set it. No in-tree caller selects individual partitions of a single-file source.Stacked on #11648.
🤖 Generated with Claude Code