Internal Jenkins has submitted this change and it was merged.

Change subject: IMPALA-2502: don't redundantly repartition grouping aggregations
......................................................................


IMPALA-2502: don't redundantly repartition grouping aggregations

Grouping aggregations previously always repartitioned their input,
even if preceding joins or aggs had already partitioned the data on the
required key (or an equivalent key). This patch checks to see if data is
already partitioned on the required exprs (or equivalent ones), and if
so skips the preaggregation and only does a merge aggregation.

The patch also does some refactoring of the aggregation planning in
DistributedPlanner to make it easier to implement the change.

Includes planner tests for the three cases that are affected:
grouping aggregations, non-grouping distinct aggregations and
grouping distinct aggregations.

Change-Id: Iffdcfd3629b8a69bd23915e1adba3b8323cbbaef
Reviewed-on: http://gerrit.cloudera.org:8080/2414
Reviewed-by: Tim Armstrong <[email protected]>
Tested-by: Internal Jenkins
---
M fe/src/main/java/com/cloudera/impala/analysis/AggregateInfo.java
M fe/src/main/java/com/cloudera/impala/planner/AnalyticPlanner.java
M fe/src/main/java/com/cloudera/impala/planner/DataPartition.java
M fe/src/main/java/com/cloudera/impala/planner/DistributedPlanner.java
M testdata/workloads/functional-planner/queries/PlannerTest/aggregation.test
M testdata/workloads/functional-planner/queries/PlannerTest/inline-view.test
M testdata/workloads/functional-planner/queries/PlannerTest/tpch-all.test
7 files changed, 286 insertions(+), 105 deletions(-)

Approvals:
  Internal Jenkins: Verified
  Tim Armstrong: Looks good to me, approved



-- 
To view, visit http://gerrit.cloudera.org:8080/2414
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Iffdcfd3629b8a69bd23915e1adba3b8323cbbaef
Gerrit-PatchSet: 10
Gerrit-Project: Impala
Gerrit-Branch: cdh5-trunk
Gerrit-Owner: Tim Armstrong <[email protected]>
Gerrit-Reviewer: Alex Behm <[email protected]>
Gerrit-Reviewer: Internal Jenkins
Gerrit-Reviewer: Marcel Kornacker <[email protected]>
Gerrit-Reviewer: Tim Armstrong <[email protected]>

Reply via email to