Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 15 additions & 3 deletions packaging/hudi-hadoop-mr-bundle/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -67,8 +67,9 @@
<includes>
<include>org.apache.hudi:hudi-common</include>
<include>org.apache.hudi:hudi-hadoop-mr</include>

<!-- Parquet -->
<include>org.apache.parquet:parquet-avro</include>
<include>org.apache.parquet:parquet-hadoop-bundle</include>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This change means that we are now bundling parquet for hive. not just parquet-avro. Should we fix the Mr bundle's parquet-avro version alone instead

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There are two proposals:
1)The read and write engines (according to spark parquet-avro version)use the same version which is the meaning of this patch
2)The read engines such as hive use their own parquet-* version

for hive2 parquet-hadoop version is 1.8.1, hive3 parquet-hadoop version is 1.10.0, which is not compatible with the version of parquet-avro.

So the second solution may take 1.8.1 for hive2, 1.10.0 for hive3 ,but has also a bit inconsistent with the write engines.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@RexXiong if we enforce parquet-avro version using a different variable say hive.parquet.version to always 1.10.x, and shade it in hadoop-mr-bundle, this should be ok ? Would parquet-avro 1.10.x work with parquet-hadoop 1.8.1 ? if so, we don't have to create hive profiles.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@xushiyan test seems parquet-avro 1.10.x is compatible with parquet-hadoop 1.8.1. So I will specify the parquet version of parquet-avro for hadoop-mr-bundle, and this solution was also the first proposed.

<include>org.apache.avro:avro</include>
<include>com.esotericsoftware:kryo-shaded</include>
<include>org.objenesis:objenesis</include>
Expand Down Expand Up @@ -131,8 +132,12 @@
<shadedPattern>org.apache.hudi.org.apache.htrace.</shadedPattern>
</relocation>
<relocation>
<pattern>org.apache.parquet.avro.</pattern>
<shadedPattern>org.apache.hudi.org.apache.parquet.avro.</shadedPattern>
<pattern>org.apache.parquet.</pattern>
<shadedPattern>org.apache.hudi.org.apache.parquet.</shadedPattern>
</relocation>
<relocation>
<pattern>shaded.parquet.</pattern>
<shadedPattern>org.apache.hudi.shaded.parquet.</shadedPattern>
</relocation>
<relocation>
<pattern>com.google.common.</pattern>
Expand Down Expand Up @@ -258,6 +263,13 @@
<scope>compile</scope>
</dependency>

<dependency>
<groupId>org.apache.parquet</groupId>
<artifactId>parquet-hadoop-bundle</artifactId>
<version>${parquet.version}</version>
<scope>compile</scope>
</dependency>

<!-- Avro -->
<dependency>
<groupId>org.apache.avro</groupId>
Expand Down