Skip to content
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

feat(frontend): add FilterMerge #2007

Merged
merged 3 commits into from
Apr 21, 2022
Merged

Conversation

likg227
Copy link
Contributor

@likg227 likg227 commented Apr 21, 2022

What's changed and what's your intention?

This pr does what the title said. Because we may split one LogicalFilter into multiple LogicalFilters using some rules(e.g. FilterJoin) and push them down, there may be a LogicalFilter directly on top of another LogicalFilter. To deal with it, I use a simple rule to merge them thus improving the optimization.

Checklist

  • I have written necessary docs and comments
  • I have added necessary unit tests and integration tests

Refer to a related PR or issue link (optional)

split from #1979

@codecov
Copy link

codecov bot commented Apr 21, 2022

Codecov Report

Merging #2007 (0e96a5a) into main (83efe76) will increase coverage by 0.02%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##             main    #2007      +/-   ##
==========================================
+ Coverage   70.77%   70.79%   +0.02%     
==========================================
  Files         627      628       +1     
  Lines       80806    80803       -3     
==========================================
+ Hits        57187    57205      +18     
+ Misses      23619    23598      -21     
Flag Coverage Δ
rust 70.79% <100.00%> (+0.02%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
...rontend/src/optimizer/plan_node/logical_project.rs 97.53% <ø> (ø)
src/frontend/src/optimizer/mod.rs 93.78% <100.00%> (+0.03%) ⬆️
src/frontend/src/optimizer/rule/filter_merge.rs 100.00% <100.00%> (ø)
...src/optimizer/rule/pull_up_correlated_predicate.rs 98.73% <100.00%> (-0.02%) ⬇️
src/meta/src/manager/stream_clients.rs 88.88% <0.00%> (-7.41%) ⬇️
src/batch/src/executor/fuse.rs 94.20% <0.00%> (-4.35%) ⬇️
src/meta/src/barrier/command.rs 56.07% <0.00%> (-2.81%) ⬇️
src/meta/src/barrier/mod.rs 69.00% <0.00%> (-1.07%) ⬇️
src/meta/src/hummock/hummock_manager.rs 91.23% <0.00%> (-0.11%) ⬇️
src/meta/src/barrier/info.rs 100.00% <0.00%> (ø)
... and 6 more

📣 Codecov can now indicate which changes are the most critical in Pull Requests. Learn more

@xiangjinwu
Copy link
Contributor

Could you elaborate why is this an improvement over the original FilterProject?

@xiangjinwu xiangjinwu changed the title feat(frontend): add FilterMerge and improve FilterJoin feat(frontend): add FilterMerge and improve FilterProject Apr 21, 2022
@xiangjinwu xiangjinwu requested a review from st1page April 21, 2022 05:27
@likg227
Copy link
Contributor Author

likg227 commented Apr 21, 2022

Sorry, I misunderstand the original implementation of FilterProject. I will fix it.

@likg227 likg227 changed the title feat(frontend): add FilterMerge and improve FilterProject feat(frontend): add FilterMerge Apr 21, 2022
@likg227 likg227 merged commit 291628b into main Apr 21, 2022
@likg227 likg227 deleted the lkg/filter-merge-and-filter-project branch April 21, 2022 05:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants