----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/22752/#review46935 -----------------------------------------------------------
ql/src/java/org/apache/hadoop/hive/ql/exec/ReduceSinkOperator.java <https://reviews.apache.org/r/22752/#comment82505> Wondering if their is a better way to do this conditional initialization, especially given Operator::acceptLimitPushdown() which will come in play when we optimize for limit clause. Though, current way work for what we are trying to optimize at the moment. ql/src/java/org/apache/hadoop/hive/ql/ppd/OpProcFactory.java <https://reviews.apache.org/r/22752/#comment82507> will be good to document that we currently optimize only for expressions like rank() < integer-constant. ql/src/java/org/apache/hadoop/hive/ql/ppd/OpProcFactory.java <https://reviews.apache.org/r/22752/#comment82506> Is this correct? Can we push for lead as well ? ql/src/java/org/apache/hadoop/hive/ql/ppd/OpProcFactory.java <https://reviews.apache.org/r/22752/#comment82508> Don't we need to do this and following check even for rank functions? Can you add some comments for this function, I didnt understand it fully. ql/src/test/queries/clientpositive/windowing_streaming.q <https://reviews.apache.org/r/22752/#comment82509> Can you also add explains for these plans, which hopefully also indicates that rank got pushed in map. Figuring whether rank got pushed or not will be useful in future for perf debugging. - Ashutosh Chauhan On June 18, 2014, 8:40 p.m., Harish Butani wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/22752/ > ----------------------------------------------------------- > > (Updated June 18, 2014, 8:40 p.m.) > > > Review request for hive and Ashutosh Chauhan. > > > Bugs: HIVE-7063 > https://issues.apache.org/jira/browse/HIVE-7063 > > > Repository: hive-git > > > Description > ------- > > It is common to rank within a Group/Partition and then only return the Top N > entries within each Group. > With Streaming mode for Windowing, we should push the post filter on the rank > into the Windowing processing as a Limit expression. > > > Diffs > ----- > > ql/src/java/org/apache/hadoop/hive/ql/exec/PTFTopNHash.java PRE-CREATION > ql/src/java/org/apache/hadoop/hive/ql/exec/ReduceSinkOperator.java 03a64e8 > ql/src/java/org/apache/hadoop/hive/ql/exec/TopNHash.java bc81467 > > ql/src/java/org/apache/hadoop/hive/ql/exec/vector/VectorReduceSinkOperator.java > 11024da > ql/src/java/org/apache/hadoop/hive/ql/plan/ReduceSinkDesc.java 8c1d336 > ql/src/java/org/apache/hadoop/hive/ql/plan/ptf/WindowTableFunctionDef.java > c547e62 > ql/src/java/org/apache/hadoop/hive/ql/ppd/OpProcFactory.java 7aaf455 > ql/src/java/org/apache/hadoop/hive/ql/udf/ptf/WindowingTableFunction.java > 2290766 > ql/src/test/queries/clientpositive/windowing_streaming.q PRE-CREATION > ql/src/test/results/clientpositive/windowing_streaming.q.out PRE-CREATION > > Diff: https://reviews.apache.org/r/22752/diff/ > > > Testing > ------- > > added new .q tests > > > Thanks, > > Harish Butani > >