>From Dmitry Lychagin <[email protected]>: Dmitry Lychagin has posted comments on this change. ( https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/12463 )
Change subject: [ASTERIXDB-2929][IDX] More robust array index applicability recognition ...................................................................... Patch Set 3: (4 comments) https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/12463/3/asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/am/AbstractIntroduceAccessMethodRule.java File asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/am/AbstractIntroduceAccessMethodRule.java: https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/12463/3/asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/am/AbstractIntroduceAccessMethodRule.java@84 PS3, Line 84: private final ArrayIndexStructureMatcher arrayIndexStructureMatcher = new ArrayIndexStructureMatcher(); can we move this field into AccessMethodAnalysisContext? It might be a better place for this helper object. https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/12463/3/asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/am/ArrayIndexStructureMatcher.java File asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/am/ArrayIndexStructureMatcher.java: https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/12463/3/asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/am/ArrayIndexStructureMatcher.java@48 PS3, Line 48: private boolean isMatchFound = true; how come 'isMatchFound'= true by default? is this intended? https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/12463/3/asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/am/ArrayIndexStructureMatcher.java@87 PS3, Line 87: public void reset(LogicalVariable var, OptimizableOperatorSubTree subTree) { let's not use "var" as a parameter name. "var" is a new keyword in JDK 11, so this might be confusing. See. https://docs.oracle.com/en/java/javase/11/language/local-variable-type-inference.html https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/12463/3/asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/util/SelectInSubplanBranchCreator.java File asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/util/SelectInSubplanBranchCreator.java: https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/12463/3/asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/util/SelectInSubplanBranchCreator.java@304 PS3, Line 304: throw new CompilationException(ErrorCode.COMPILATION_ERROR, workingSubplanRoot.getSourceLocation(), is this a sanity check? if it's not then can we just exit this rewriting code without making any change? Rules should not fail if they encounter an unexpected plan pattern. -- To view, visit https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/12463 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: I709b74ea72f63eeba12876a05dac508e6a03c4f4 Gerrit-Change-Number: 12463 Gerrit-PatchSet: 3 Gerrit-Owner: Glenn Galvizo <[email protected]> Gerrit-Reviewer: Anon. E. Moose #1000171 Gerrit-Reviewer: Dmitry Lychagin <[email protected]> Gerrit-Reviewer: Glenn Galvizo <[email protected]> Gerrit-Reviewer: Jenkins <[email protected]> Gerrit-Comment-Date: Fri, 30 Jul 2021 16:31:06 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: No Gerrit-MessageType: comment
