beam-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Aviem Zur (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (BEAM-2954) opt-out shade in extension/sql
Date Wed, 13 Sep 2017 19:48:01 GMT

    [ https://issues.apache.org/jira/browse/BEAM-2954?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16165183#comment-16165183
] 

Aviem Zur commented on BEAM-2954:
---------------------------------

We cannot opt-out of the shading rules in the SQL module as we cannot leak Guava to our users.

If a shaded version of {{Calcite}} exists which relocates {{Guava}} we should use that (such
a version does not seem to exist). Otherwise, since {{Calcite}} is under {{Apache License
2.0}} we can shade it into our SQL module, using the same relocation rules applied in {{beam-parent}}.

> opt-out shade in extension/sql
> ------------------------------
>
>                 Key: BEAM-2954
>                 URL: https://issues.apache.org/jira/browse/BEAM-2954
>             Project: Beam
>          Issue Type: Bug
>          Components: dsl-sql
>            Reporter: Xu Mingmin
>            Assignee: Xu Mingmin
>              Labels: 2.2.0, shade, sql
>             Fix For: 2.2.0
>
>
> {{guava}} is shaded by default in beam modules, while {{calcite}}(a dependency of SQL)
includes {{guava}} which is not shaded. Below error is thrown when calling {{calcite}} methods
with guava classed.
> {code}
> Exception in thread "main" java.lang.NoSuchMethodError: org.apache.calcite.rel.core.Aggregate.getGroupSets()Lorg/apache/beam/sdks/java/extensions/sql/repackaged/com/google/common/collect/ImmutableList;
> 	at org.apache.beam.sdk.extensions.sql.impl.rule.BeamAggregationRule.updateWindowTrigger(BeamAggregationRule.java:139)
> 	at org.apache.beam.sdk.extensions.sql.impl.rule.BeamAggregationRule.onMatch(BeamAggregationRule.java:73)
> 	at org.apache.calcite.plan.volcano.VolcanoRuleCall.onMatch(VolcanoRuleCall.java:212)
> 	at org.apache.calcite.plan.volcano.VolcanoPlanner.findBestExp(VolcanoPlanner.java:650)
> 	at org.apache.calcite.tools.Programs$RuleSetProgram.run(Programs.java:368)
> 	at org.apache.calcite.prepare.PlannerImpl.transform(PlannerImpl.java:313)
> 	at org.apache.beam.sdk.extensions.sql.impl.planner.BeamQueryPlanner.convertToBeamRel(BeamQueryPlanner.java:149)
> 	at org.apache.beam.sdk.extensions.sql.impl.planner.BeamQueryPlanner.validateAndConvert(BeamQueryPlanner.java:140)
> 	at org.apache.beam.sdk.extensions.sql.impl.planner.BeamQueryPlanner.convertToBeamRel(BeamQueryPlanner.java:128)
> 	at org.apache.beam.sdk.extensions.sql.impl.planner.BeamQueryPlanner.compileBeamPipeline(BeamQueryPlanner.java:113)
> 	at org.apache.beam.sdk.extensions.sql.impl.BeamSqlCli.compilePipeline(BeamSqlCli.java:62)
> 	at com.ebay.dss.beam_sql_demo.ToraSqlCli.executeQuery(ToraSqlCli.java:72)
> 	at com.ebay.dss.beam_sql_demo.ToraSqlCli.exec(ToraSqlCli.java:111)
> 	at com.ebay.dss.beam_sql_demo.ToraSqlCli.main(ToraSqlCli.java:130)
> {code}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Mime
View raw message