You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by GitBox <gi...@apache.org> on 2022/11/17 13:05:39 UTC
[GitHub] [doris] yinzhijian opened a new pull request, #14377: [improvement](planner) eliminating useless sort node
yinzhijian opened a new pull request, #14377:
URL: https://github.com/apache/doris/pull/14377
# Proposed changes
Issue Number: close #xxx
## Problem summary
### for example
```select k1 from tbl1 where k3 = 3 and k2 = 2 and k1 = 1 order by k1, k2 ```
## Checklist(Required)
1. Does it affect the original behavior:
- [ ] Yes
- [ ] No
- [ ] I don't know
2. Has unit tests been added:
- [ ] Yes
- [ ] No
- [ ] No Need
3. Has document been added or modified:
- [ ] Yes
- [ ] No
- [ ] No Need
4. Does it need to update dependencies:
- [ ] Yes
- [ ] No
5. Are there any changes that cannot be rolled back:
- [ ] Yes (If Yes, please explain WHY)
- [ ] No
## Further comments
If this is a relatively large or complex change, kick off the discussion at [dev@doris.apache.org](mailto:dev@doris.apache.org) by explaining why you chose the solution you did and what alternatives you considered, etc...
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
[GitHub] [doris] yinzhijian commented on a diff in pull request #14377: [improvement](planner) eliminating useless sort node
Posted by GitBox <gi...@apache.org>.
yinzhijian commented on code in PR #14377:
URL: https://github.com/apache/doris/pull/14377#discussion_r1027225986
##########
fe/fe-core/src/main/java/org/apache/doris/qe/SessionVariable.java:
##########
@@ -586,6 +588,9 @@ public class SessionVariable implements Serializable, Writable {
@VariableMgr.VarAttr(name = ENABLE_NEREIDS_STATS_DERIVE_V2)
public boolean enableNereidsStatsDeriveV2 = false;
+ @VariableMgr.VarAttr(name = ENABLE_ELIMINATE_SORT_NODE)
+ public boolean enableEliminateSortNode = true;
Review Comment:
The main concern is that there may be an unknown problem that can be recovered by turning it off
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
[GitHub] [doris] hello-stephen commented on pull request #14377: [improvement](planner) eliminating useless sort node
Posted by GitBox <gi...@apache.org>.
hello-stephen commented on PR #14377:
URL: https://github.com/apache/doris/pull/14377#issuecomment-1318765847
TeamCity pipeline, clickbench performance test result:
the sum of best hot time: 35.3 seconds
load time: 443 seconds
storage size: 17171591398 Bytes
https://doris-community-test-1308700295.cos.ap-hongkong.myqcloud.com/tmp/20221117150141_clickbench_pr_48132.html
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
[GitHub] [doris] yangzhg commented on a diff in pull request #14377: [improvement](planner) eliminating useless sort node
Posted by GitBox <gi...@apache.org>.
yangzhg commented on code in PR #14377:
URL: https://github.com/apache/doris/pull/14377#discussion_r1025943331
##########
fe/fe-core/src/main/java/org/apache/doris/planner/SingleNodePlanner.java:
##########
@@ -240,8 +242,12 @@ private PlanNode createQueryPlan(QueryStmt stmt, Analyzer analyzer, long default
newDefaultOrderByLimit = 65535;
}
PlanNode root;
+ boolean canEliminatingSortNode = false;
if (stmt instanceof SelectStmt) {
SelectStmt selectStmt = (SelectStmt) stmt;
+ if (ConnectContext.get() != null && ConnectContext.get().getSessionVariable().enableEliminateSortNode) {
Review Comment:
move this check to `canEliminatingSortNode` func?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
[GitHub] [doris] yangzhg merged pull request #14377: [improvement](planner) eliminating useless sort node
Posted by GitBox <gi...@apache.org>.
yangzhg merged PR #14377:
URL: https://github.com/apache/doris/pull/14377
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org