[
https://issues.apache.org/jira/browse/IMPALA-15299?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Aleksandr Efimov resolved IMPALA-15299.
---------------------------------------
Resolution: Duplicate
Folded into IMPALA-15296 before review. The work was first cut one sub-task per
finding, which came to nine on top of the two the series started with;
regrouped by subject so that a reviewer reads the mechanism once and the
applications after it. Nothing described here is dropped: the code and the
reasoning both live on in IMPALA-15296, and the Gerrit change was abandoned
with the same note.
> Calcite planner: cover grouping sets in the Substrait export tests
> ------------------------------------------------------------------
>
> Key: IMPALA-15299
> URL: https://issues.apache.org/jira/browse/IMPALA-15299
> Project: IMPALA
> Issue Type: Sub-task
> Components: Frontend
> Reporter: Aleksandr Efimov
> Assignee: Aleksandr Efimov
> Priority: Major
> Labels: substrait
>
> The Substrait exporter added by IMPALA-15296 is covered by query shapes that
> came from the direct harness, and none of them group by more than one set.
> Impala produces such aggregates: CoerceNodes rebuilds the LogicalAggregate
> with getGroupSets() untouched, and ImpalaAggRel builds one set of expressions
> per set, so grouping sets, rollup and cube all reach the seam as a real
> multi-set aggregate.
> They export today, without anything added to the exporter, and nothing says
> so. Cover them, so that a change at the seam that flattens or reorders the
> sets is caught here rather than somewhere downstream.
> Cover the other half too. Neither grouping() nor grouping_id() converts:
> Substrait has no grouping function and Isthmus does not synthesise one, which
> is substrait-java#993. The shape of the query makes no difference, sets or
> rollup or cube, one column or several, so a single case per function is
> enough. These belong in the tests as expected rejections rather than as
> candidates, since the fix is not ours to make.
> The assertions are on the plan rather than on its bytes, and the sets name
> their fields in ascending order of first appearance. substrait-java#1161
> moves the difference between Substrait's column order for a multi-set
> aggregate and Calcite's into the aggregate's emit mapping, and states that a
> plan already agreeing with Calcite round-trips unchanged, so shapes written
> this way are the ones that survive that upgrade.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]