Uh oh!
There was an error while loading. Please reload this page.
[SPARK-13936] [SQL] Avoid Predicate Pushdown Using Constraints in PushPredicateThroughProject - #11765
[SPARK-13936] [SQL] Avoid Predicate Pushdown Using Constraints in PushPredicateThroughProject#11765gatorsmile wants to merge 3 commits into
Conversation
SparkQA
commented
Mar 16, 2016
Test build #53328 has finished for PR 11765 at commit
|
SparkQA
commented
Mar 16, 2016
Test build #53329 has finished for PR 11765 at commit
|
gatorsmile
commented
Mar 16, 2016
davies
commented
Mar 18, 2016
@gatorsmile Should we fix this in InferFiltersFromConstraints itself? |
gatorsmile
commented
Mar 19, 2016
@davies, changing |
sameeragarwal
commented
Mar 21, 2016
@gatorsmile isn't the issue that you pointed out in the PR description just an artifact of union not propagating constraints correctly when it encounters a |
gatorsmile
commented
Mar 21, 2016
@sameeragarwal That is just an example that exposes this issue. I think |
srowen
commented
Jun 23, 2016
Same, is this still an issue, active? |
gatorsmile
commented
Jun 23, 2016
The issue has been resolved. Let me close it. Thanks! |
What changes were proposed in this pull request?
In the query, Optimizer keeps adding duplicate constraints in Filter constraints by applying the rule PushPredicateThroughProject.
The generated optimized plan is like
Due to this issue, it also hits the max iteration, as shown in the log output https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/53176/consoleFull.
This PR uses the constraints to avoid pushing any predicate that already exists in its child's Constraints. Also, it will not pushing any predicate that does not contain any reference, since it could introduce the same issue.
Will introduce the same idea in the similar rules:
Should I do it in the same PR? or different PRs? @marmbrus
How was this patch tested?
Added a test case and also manually tested the case that causes the exception in #11714