>From Vijay Sarathy <[email protected]>:

Attention is currently required from: Till Westmann, 
[email protected].
Vijay Sarathy has posted comments on this change. ( 
https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/17765 )

Change subject: [ASTERIXDB-3246][COMP]: CBO costing of all physical operators 
in a query plan
......................................................................


Patch Set 17:

(11 comments)

File 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/cost/CostMethods.java:

https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/17765/comment/06696182_72b90a37
PS16, Line 90: /
> Keep width under 120 characters
Done


File 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/cbo/EnumerateJoinsRule.java:

https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/17765/comment/3f7dc527_59f8756a
PS16, Line 136:
> revert?
Done


https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/17765/comment/ef900732_13d87cb1
PS16, Line 92: ILogicalOperator
> Keep width under 120 characters
Done


File 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/cbo/JoinEnum.java:

https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/17765/comment/c3578649_bdfcdcb2
PS16, Line 110:     protected ILogicalOperator rootGroupByDistinctOp; // The 
Distinct/GroupBy operator at root of the query tree (if exists)
> Keep width under 120 characters
Done


File 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/cbo/JoinNode.java:

https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/17765/comment/21e34c83_4cdd8bc0
PS16, Line 1063:             // Other heuristic formulas considered for 
computing distinct cardinality estimates of joins.
               :             // These are commented out for now, but can be 
experimented with if needed.
               :
               :             // 1. The mid of upper and lower bounds
               :             // D_est_jn = (max(D_est_l, D_est_r) + D_est_l * 
D_est_r)/ 2
               :             /* this.distinctCardinality = 
(Math.max(leftJn.distinctCardinality, rightJn.distinctCardinality)
               :                     + leftJn.distinctCardinality * 
rightJn.distinctCardinality) / 2.0;
               :              */
               :
               :             // 2. Compute heuristically D_est_jn (either lower 
bound or mid of upper and lower bounds)
               :             /*
               :             double minVal = 
Math.min(leftJn.distinctCardinality, rightJn.distinctCardinality);
               :             double maxVal = 
Math.max(leftJn.distinctCardinality, rightJn.distinctCardinality);
               :             double ratio = (double) Math.round(minVal / maxVal 
* 1000) / 1000;
               :             this.distinctCardinality = (ratio > 0.001) ? maxVal
               :                     : ((maxVal + leftJn.distinctCardinality * 
rightJn.distinctCardinality) / 2.0);
               :              */
               :
               :             // 3. Heuristic used currently
               :             // D_est_jn = (D_est_l > D_est_r) ? (D_est_l * 
join productivity of leftJn) : (D_est_r * join productivity of rightJn)
> Do we need to keep the commented code? If so, please keep width under 120 
> characters
Done


File 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/cbo/OperatorUtils.java:

https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/17765/comment/770d2975_aadbe0d2
PS16, Line 116:                     /*if 
(containsAllGroupByDistinctVarsInScanOp(scanOp, grpByDistinctOp)) {
              :                         // contains all PK attribute(s), so 
estimated distinct cardinality is same as original dataset cardinality
              :                         scanOp = null;
              :                     } else { // at least one PK attribute is 
not in GroupByOp or DistinctOp variables */
> Can we remove the commented code?
Done


https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/17765/comment/1ca0c40d_6b18d891
PS16, Line 228: all
> Keep width under 120 characters
Done


File 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/aggregate/non-pure-function/non-pure-function.04.query.sqlpp:

https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/17765/comment/d9cc992d_4313ba54
PS16, Line 26: +
> revert?
Done


File 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/tinysocial/tinysocial-suite-open/tinysocial-suite.4.query.sqlpp:

https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/17765/comment/90323dea_02292ab5
PS16, Line 25:
> revert
Done


File 
asterixdb/asterix-app/src/test/resources/runtimets/results/tpcds/q05/q05.1.adm:

https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/17765/comment/864ba419_70b317b7
PS16, Line 15: { "channel": "web channel", "id": "web_siteAAAAAAAAEAAAAAAA", 
"sales": 10226.26, "returns": 3656.08, "profit": -7059.47 }
> revert
Done


File 
hyracks-fullstack/algebricks/algebricks-rewriter/src/main/java/org/apache/hyracks/algebricks/rewriter/rules/SetAlgebricksPhysicalOperatorsRule.java:

https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/17765/comment/7bca6140_d21afdaa
PS16, Line 204: ;
> one is sufficient
Done



--
To view, visit https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/17765
To unsubscribe, or for help writing mail filters, visit 
https://asterix-gerrit.ics.uci.edu/settings

Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Change-Id: I3196f664d716bb5b3806ec9a5a0dd5c1ea51ff62
Gerrit-Change-Number: 17765
Gerrit-PatchSet: 17
Gerrit-Owner: Vijay Sarathy <[email protected]>
Gerrit-Reviewer: Ali Alsuliman <[email protected]>
Gerrit-Reviewer: Anon. E. Moose #1000171
Gerrit-Reviewer: Jenkins <[email protected]>
Gerrit-Reviewer: Till Westmann <[email protected]>
Gerrit-Reviewer: Vijay Sarathy <[email protected]>
Gerrit-Reviewer: [email protected]
Gerrit-Attention: Till Westmann <[email protected]>
Gerrit-Attention: [email protected]
Gerrit-Comment-Date: Tue, 24 Oct 2023 18:58:46 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: Till Westmann <[email protected]>
Gerrit-MessageType: comment

Reply via email to