You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues-all@impala.apache.org by "Tim Armstrong (JIRA)" <ji...@apache.org> on 2018/07/11 17:23:00 UTC
[jira] [Assigned] (IMPALA-5029) Remove un-necessary exchange
operators from scan+agg queries when hosts=1
[ https://issues.apache.org/jira/browse/IMPALA-5029?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Tim Armstrong reassigned IMPALA-5029:
-------------------------------------
Assignee: (was: Alexander Behm)
> Remove un-necessary exchange operators from scan+agg queries when hosts=1
> -------------------------------------------------------------------------
>
> Key: IMPALA-5029
> URL: https://issues.apache.org/jira/browse/IMPALA-5029
> Project: IMPALA
> Issue Type: Bug
> Components: Frontend
> Affects Versions: Impala 2.6.0
> Reporter: Mostafa Mokhtar
> Priority: Minor
>
> Lightweight queries that constitute a small scan followed by an aggregate and hosts=1 can be optimized by doing a final aggregate opposed to streaming -> exchange -> Final
> {code}
> select count (distinct n_nationkey) from nation
> {code}
> Plan
> {code}
> +----------------------------------------------------------+
> | Explain String |
> +----------------------------------------------------------+
> | Estimated Per-Host Requirements: Memory=36.00MB VCores=2 |
> | |
> | PLAN-ROOT SINK |
> | | |
> | 06:AGGREGATE [FINALIZE] |
> | | output: count:merge(n_nationkey) |
> | | hosts=1 per-host-mem=unavailable |
> | | tuple-ids=2 row-size=8B cardinality=1 |
> | | |
> | 05:EXCHANGE [UNPARTITIONED] |
> | | hosts=1 per-host-mem=unavailable |
> | | tuple-ids=2 row-size=8B cardinality=1 |
> | | |
> | 02:AGGREGATE |
> | | output: count(n_nationkey) |
> | | hosts=1 per-host-mem=10.00MB |
> | | tuple-ids=2 row-size=8B cardinality=1 |
> | | |
> | 04:AGGREGATE |
> | | group by: n_nationkey |
> | | hosts=1 per-host-mem=10.00MB |
> | | tuple-ids=1 row-size=8B cardinality=25 |
> | | |
> | 03:EXCHANGE [HASH(n_nationkey)] |
> | | hosts=1 per-host-mem=0B |
> | | tuple-ids=1 row-size=8B cardinality=25 |
> | | |
> | 01:AGGREGATE [STREAMING] |
> | | group by: n_nationkey |
> | | hosts=1 per-host-mem=10.00MB |
> | | tuple-ids=1 row-size=8B cardinality=25 |
> | | |
> | 00:SCAN HDFS [tpch_300_parquet.nation, RANDOM] |
> | partitions=1/1 files=1 size=2.19KB |
> | table stats: 25 rows total |
> | column stats: all |
> | hosts=1 per-host-mem=16.00MB |
> | tuple-ids=0 row-size=8B cardinality=25 |
> +----------------------------------------------------------+
> {code}
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-all-unsubscribe@impala.apache.org
For additional commands, e-mail: issues-all-help@impala.apache.org