siddharthteotia commented on code in PR #10248: URL: https://github.com/apache/pinot/pull/10248#discussion_r1118301734
########## pinot-query-planner/src/main/java/org/apache/calcite/rel/hint/PinotHintStrategyTable.java: ########## @@ -18,19 +18,36 @@ */ package org.apache.calcite.rel.hint; +import com.google.common.collect.ImmutableList; + + /** * Default hint strategy set for Pinot query. */ public class PinotHintStrategyTable { public static final String INTERNAL_AGG_INTERMEDIATE_STAGE = "aggIntermediateStage"; public static final String INTERNAL_AGG_FINAL_STAGE = "aggFinalStage"; + public static final String SKIP_LEAF_STAGE_GROUP_BY_AGGREGATION = "skipLeafStageGroupByAggregation"; + + + private PinotHintStrategyTable() { // do not instantiate. } public static final HintStrategyTable PINOT_HINT_STRATEGY_TABLE = HintStrategyTable.builder() .hintStrategy(INTERNAL_AGG_INTERMEDIATE_STAGE, HintPredicates.AGGREGATE) .hintStrategy(INTERNAL_AGG_FINAL_STAGE, HintPredicates.AGGREGATE) + .hintStrategy(SKIP_LEAF_STAGE_GROUP_BY_AGGREGATION, HintPredicates.AGGREGATE) .build(); + + public static boolean containsHint(ImmutableList<RelHint> hintList, String hintName) { + for (RelHint relHint : hintList) { + if (relHint.hintName.equals(hintName)) { Review Comment: Should this be `equalsIgnoreCase` ? -- 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-unsubscr...@pinot.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org For additional commands, e-mail: commits-h...@pinot.apache.org