-
Notifications
You must be signed in to change notification settings - Fork 277
fix: use inputRDD to get outputPartitions in CometScanExec #1162
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -132,7 +132,7 @@ case class CometScanExec( | |
| lazy val bucketedScan: Boolean = wrapped.bucketedScan | ||
|
|
||
| override lazy val (outputPartitioning, outputOrdering): (Partitioning, Seq[SortOrder]) = | ||
| (wrapped.outputPartitioning, wrapped.outputOrdering) | ||
| (UnknownPartitioning(wrapped.inputRDD.getNumPartitions), wrapped.outputOrdering) | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Btw, I think we should keep original partition instead a hard-coded
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I did this based on what we do in CometNativeScanExec as well as the original output partition. The original wrapped.outputPartitioning for CometScanExec inherits from FileSourceScanLike and this returns a hardcoded
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Okay |
||
|
|
||
| @transient | ||
| private lazy val pushedDownFilters = getPushedDownFilters(relation, dataFilters) | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What the output partitioning is when it fails the test? I assume that the
outputPartitioningshould have correct partition number but not?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We were seeing zero partitions. Here is some debug output from testing:
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Correct.
wrapped.outputPartitioningwas zeroThere was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is somehow weird. It means the
outputPartitioninginfo is not correct in original ScanExec and not matched the output RDD's partition number. 🤔