>From Vijay Sarathy <[email protected]>:

Attention is currently required from: Mehnaz Tabassum Mahin.
Vijay Sarathy has posted comments on this change. ( 
https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/18131 )

Change subject: [NO ISSUE][COMP] Fix compile time errors in Distinct 
Cardinality Estimation
......................................................................


Patch Set 1:

(5 comments)

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

https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/18131/comment/75abb0e9_0c2f7902
PS1, Line 452: LogicalOperatorTag
I have been advised by other team members during prior reviews that we should 
not be manipulating function arguments, and should instead use a local variable 
(like currentOp). So, please restore the use of currentOp throughput this 
method.


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

https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/18131/comment/0aa126b8_d712e87d
PS1, Line 53: map
Earlier name (scanAndDisticntOps) was more descriptive, please use that unless 
there is a good reason not to.


https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/18131/comment/8262197a_25130627
PS1, Line 61:         LogicalOperatorTag tag = op.getOperatorTag();
Same comment about not manipulating function arguments.


https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/18131/comment/5eb26968_f6706fbd
PS1, Line 180:             return new Pair<>(distinctVars, distinctFunctions);
We ran into an issue (don't remember the details fully now), when distinctVars 
and distinctFunctions were split up, that's why I had to consolidate them into 
one. Any reason why you split them again like you had in your initial code? I 
think the test that crashed was not in the jenkins test suite, so that's why 
you are not seeing any issues. So, I would keep the code as before. Also, would 
be passing in less parameters to methods.

Pair<List<LogicalVariable>, List<AbstractFunctionCallExpression>> 
distinctVarsFunctions =
                new Pair<>(new ArrayList<>(), new ArrayList<>());
        List<LogicalVariable> distinctVars = distinctVarsFunctions.getFirst();
        List<AbstractFunctionCallExpression> distinctFunctions = 
distinctVarsFunctions.getSecond();

        if (grpByDistinctOp == null) {
            return distinctVarsFunctions;


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

https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/18131/comment/02efb0a2_59874037
PS1, Line 902:             parent = op;
Same comment as before about not manipulating function arguments.



--
To view, visit https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/18131
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: Ic31c3109a1f9cfc4ae12fb3a49273142973b240b
Gerrit-Change-Number: 18131
Gerrit-PatchSet: 1
Gerrit-Owner: Mehnaz Tabassum Mahin <[email protected]>
Gerrit-Reviewer: Anon. E. Moose #1000171
Gerrit-Reviewer: Ian Maxon <[email protected]>
Gerrit-Reviewer: Jenkins <[email protected]>
Gerrit-Reviewer: Vijay Sarathy <[email protected]>
Gerrit-Reviewer: [email protected]
Gerrit-Attention: Mehnaz Tabassum Mahin <[email protected]>
Gerrit-Comment-Date: Wed, 24 Jan 2024 22:29:45 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Gerrit-MessageType: comment

Reply via email to