kasakrisz commented on a change in pull request #1096:
URL: https://github.com/apache/hive/pull/1096#discussion_r439922505
##########
File path: ql/src/java/org/apache/hadoop/hive/ql/parse/CalcitePlanner.java
##########
@@ -2389,6 +2390,11 @@ private RelNode applyPostJoinOrderingTransform(RelNode
basePlan, RelMetadataProv
final HepProgramBuilder program = new HepProgramBuilder();
+ if
(conf.getBoolVar(ConfVars.HIVE_CARDINALITY_PRESERVING_JOIN_OPTIMIZATION)) {
+ generatePartialProgram(program, false, HepMatchOrder.TOP_DOWN,
+ new HiveCardinalityPreservingJoinRule());
Review comment:
`HiveCardinalityPreservingJoinRule` is not stateless: it extends
`HiveFieldTrimmerRule` which tracks whether it was triggered or not to avoid
unnecessary multiple traversals.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]