[improvement](External Catalog) Remove unnecessary conjuncts handling in External Catalog#41218
Merged
morrySnow merged 2 commits intoapache:masterfrom Oct 17, 2024
Merged
Conversation
|
Thank you for your contribution to Apache Doris. Since 2024-03-18, the Document has been moved to doris-website. |
Member
Author
|
run buildall |
morrySnow
reviewed
Sep 24, 2024
| @Override | ||
| public void init(Analyzer analyzer) throws UserException { | ||
| super.init(analyzer); | ||
| buildQuery(); |
Contributor
There was a problem hiding this comment.
do not modify legacy planner
897bda4 to
db088ff
Compare
Member
Author
|
run buildall |
db088ff to
7e36a14
Compare
Member
Author
|
run buildall |
6d91294 to
7bec2a1
Compare
7bec2a1 to
34701b2
Compare
Contributor
|
run buildall |
Contributor
|
PR approved by at least one committer and no changes requested. |
Contributor
|
PR approved by anyone and no changes requested. |
34701b2 to
1f6d21b
Compare
Member
Author
|
run buildall |
Member
Author
|
run buildall |
2 similar comments
Member
Author
|
run buildall |
Member
Author
|
run buildall |
… in External Catalog
81ebfa3 to
0828a41
Compare
Member
Author
|
run buildall |
Member
Author
|
run buildall |
Contributor
|
PR approved by at least one committer and no changes requested. |
wuwenchi
approved these changes
Oct 16, 2024
CalvinKirs
approved these changes
Oct 16, 2024
morrySnow
reviewed
Oct 16, 2024
Member
Author
Yes, such as: test_hive_partition, test_hive_default_partition |
zy-kkk
added a commit
to zy-kkk/doris
that referenced
this pull request
Oct 22, 2024
…apache#41218) In the previous FileScanNode, some parts that used conjuncts for predicate conversion were placed in the init phase. However, for the Nereids planner, pushing the filter down to the scan happens in the Translator, which means that the ScanNode can only get the complete conjuncts in the finalized phase. Therefore, in this PR, I have removed all conjuncts variables in External for the Nereids planner. They no longer need to store conjuncts themselves or add them to the ScanNode. Instead, all places in the ScanNode that use conjuncts should be moved to the finalized phase. This refactor also fix a performance issue introduced from apache#40176 After introducing the change of generating SelectNode for consecutive projects or filters, FileScan still adds conjuncts too early in the init phase, resulting in the discovery of consecutive filters when the upper layer continues to translate, a selectnode was unexpectedly generated on the scannode, causing the project to be unable to prune the scannode columns. However, the Project node trims columns of SelectNode and ScanNode differently, which causes ScanNode to scan unnecessary columns. My modification removes the addition of conjuncts in the scannode step, so that we can keep the structure from ScanNode to Project and achieve correct column trimming.
morningman
pushed a commit
that referenced
this pull request
Oct 22, 2024
… Scan (#42261) pick (#41218) In the previous FileScanNode, some parts that used conjuncts for predicate conversion were placed in the init phase. However, for the Nereids planner, pushing the filter down to the scan happens in the Translator, which means that the ScanNode can only get the complete conjuncts in the finalized phase. Therefore, in this PR, I have removed all conjuncts variables in External for the Nereids planner. They no longer need to store conjuncts themselves or add them to the ScanNode. Instead, all places in the ScanNode that use conjuncts should be moved to the finalized phase. This refactor also fix a performance issue introduced from #40176 After introducing the change of generating SelectNode for consecutive projects or filters, FileScan still adds conjuncts too early in the init phase, resulting in the discovery of consecutive filters when the upper layer continues to translate, a selectnode was unexpectedly generated on the scannode, causing the project to be unable to prune the scannode columns. However, the Project node trims columns of SelectNode and ScanNode differently, which causes ScanNode to scan unnecessary columns. My modification removes the addition of conjuncts in the scannode step, so that we can keep the structure from ScanNode to Project and achieve correct column trimming.
zy-kkk
added a commit
to zy-kkk/doris
that referenced
this pull request
Oct 31, 2024
…apache#41218) In the previous FileScanNode, some parts that used conjuncts for predicate conversion were placed in the init phase. However, for the Nereids planner, pushing the filter down to the scan happens in the Translator, which means that the ScanNode can only get the complete conjuncts in the finalized phase. Therefore, in this PR, I have removed all conjuncts variables in External for the Nereids planner. They no longer need to store conjuncts themselves or add them to the ScanNode. Instead, all places in the ScanNode that use conjuncts should be moved to the finalized phase. This refactor also fix a performance issue introduced from apache#40176 After introducing the change of generating SelectNode for consecutive projects or filters, FileScan still adds conjuncts too early in the init phase, resulting in the discovery of consecutive filters when the upper layer continues to translate, a selectnode was unexpectedly generated on the scannode, causing the project to be unable to prune the scannode columns. However, the Project node trims columns of SelectNode and ScanNode differently, which causes ScanNode to scan unnecessary columns. My modification removes the addition of conjuncts in the scannode step, so that we can keep the structure from ScanNode to Project and achieve correct column trimming.
morningman
pushed a commit
that referenced
this pull request
Oct 31, 2024
… Scan (#43018) bp (#41218) In the previous FileScanNode, some parts that used conjuncts for predicate conversion were placed in the init phase. However, for the Nereids planner, pushing the filter down to the scan happens in the Translator, which means that the ScanNode can only get the complete conjuncts in the finalized phase. Therefore, in this PR, I have removed all conjuncts variables in External for the Nereids planner. They no longer need to store conjuncts themselves or add them to the ScanNode. Instead, all places in the ScanNode that use conjuncts should be moved to the finalized phase. This refactor also fix a performance issue introduced from #40176 After introducing the change of generating SelectNode for consecutive projects or filters, FileScan still adds conjuncts too early in the init phase, resulting in the discovery of consecutive filters when the upper layer continues to translate, a selectnode was unexpectedly generated on the scannode, causing the project to be unable to prune the scannode columns. However, the Project node trims columns of SelectNode and ScanNode differently, which causes ScanNode to scan unnecessary columns. My modification removes the addition of conjuncts in the scannode step, so that we can keep the structure from ScanNode to Project and achieve correct column trimming.
16 tasks
morningman
pushed a commit
that referenced
this pull request
Dec 6, 2024
) ### What problem does this PR solve? Problem Summary: In the previous PR #41218, some partition pruning logic was changed, which caused the hudi partition pruning to fail. This PR is to fix this problem. ### Release note [fix](hudi) fix hudi partition prune issue
github-actions bot
pushed a commit
that referenced
this pull request
Dec 6, 2024
) ### What problem does this PR solve? Problem Summary: In the previous PR #41218, some partition pruning logic was changed, which caused the hudi partition pruning to fail. This PR is to fix this problem. ### Release note [fix](hudi) fix hudi partition prune issue
github-actions bot
pushed a commit
that referenced
this pull request
Dec 6, 2024
) ### What problem does this PR solve? Problem Summary: In the previous PR #41218, some partition pruning logic was changed, which caused the hudi partition pruning to fail. This PR is to fix this problem. ### Release note [fix](hudi) fix hudi partition prune issue
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.
In the previous FileScanNode, some parts that used conjuncts for predicate conversion were placed in the init phase. However, for the Nereids planner, pushing the filter down to the scan happens in the Translator, which means that the ScanNode can only get the complete conjuncts in the finalized phase. Therefore, in this PR, I have removed all conjuncts variables in External for the Nereids planner. They no longer need to store conjuncts themselves or add them to the ScanNode. Instead, all places in the ScanNode that use conjuncts should be moved to the finalized phase.
This refactor also fix a performance issue introduced from #40176
After introducing the change of generating SelectNode for consecutive projects or filters, FileScan still adds conjuncts too early in the init phase, resulting in the discovery of consecutive filters when the upper layer continues to translate, a selectnode was unexpectedly generated on the scannode, causing the project to be unable to prune the scannode columns. However, the Project node trims columns of SelectNode and ScanNode differently, which causes ScanNode to scan unnecessary columns.
My modification removes the addition of conjuncts in the scannode step, so that we can keep the structure from ScanNode to Project and achieve correct column trimming.