Skip to content

Commit

Permalink
PHOENIX-4466 Relocate Avatica and hadoop-common in thin-client jar (T…
Browse files Browse the repository at this point in the history
…oshihiro Suzuki)

When using the thin-client in Spark, we encounter problems in that Spark
is placing its own version of avatica on the classpath as well. We can
relocate most of Avatica (all but the protobuf generated messages as
their classnames are required to be 'org.apache.calcite.avatica.proto'
presently) and hadoop-common to avoid future problems.
  • Loading branch information
joshelser authored and jtaylor-sfdc committed Dec 22, 2017
1 parent ae72d05 commit e2c06b0
Showing 1 changed file with 13 additions and 3 deletions.
16 changes: 13 additions & 3 deletions phoenix-queryserver-client/pom.xml
Expand Up @@ -123,9 +123,19 @@
<shadedPattern>${shaded.package}.com.google.protobuf</shadedPattern>
</relocation>
<!-- ORG relocation -->
<!-- Calcite/Avatica is not relocated because the wire API (as of <=1.8.0) expects
consistent class names on client and server. Relocating these would break
backwards compatibility. -->
<relocation>
<pattern>org.apache.calcite.avatica</pattern>
<shadedPattern>${shaded.package}.org.apache.calcite.avatica</shadedPattern>
<!-- The protobuf messages can't be relocated due to a limitation
in the Avatica protocol. -->
<excludes>
<exclude>org.apache.calcite.avatica.proto.*</exclude>
</excludes>
</relocation>
<relocation>
<pattern>org.apache.hadoop</pattern>
<shadedPattern>${shaded.package}.org.apache.hadoop</shadedPattern>
</relocation>
<relocation>
<pattern>org.apache.commons</pattern>
<shadedPattern>${shaded.package}.org.apache.commons</shadedPattern>
Expand Down

0 comments on commit e2c06b0

Please sign in to comment.