hive-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sp...@apache.org
Subject hive git commit: HIVE-10975: Update parquet version up to 1.8.0 (Ferdinand Xu, reviewed by Sergio Pena)
Date Sun, 09 Aug 2015 22:44:33 GMT
Repository: hive
Updated Branches:
  refs/heads/master aaa34539a -> 3e68cdc99


HIVE-10975: Update parquet version up to 1.8.0 (Ferdinand Xu, reviewed by Sergio Pena)


Project: http://git-wip-us.apache.org/repos/asf/hive/repo
Commit: http://git-wip-us.apache.org/repos/asf/hive/commit/3e68cdc9
Tree: http://git-wip-us.apache.org/repos/asf/hive/tree/3e68cdc9
Diff: http://git-wip-us.apache.org/repos/asf/hive/diff/3e68cdc9

Branch: refs/heads/master
Commit: 3e68cdc9962cacab59ee891fcca6a736ad10d37d
Parents: aaa3453
Author: Sergio Pena <sergio.pena@cloudera.com>
Authored: Sun Aug 9 17:43:20 2015 -0500
Committer: Sergio Pena <sergio.pena@cloudera.com>
Committed: Sun Aug 9 17:43:20 2015 -0500

----------------------------------------------------------------------
 pom.xml                                                   |  2 +-
 .../hive/ql/io/parquet/read/DataWritableReadSupport.java  | 10 +++++++---
 2 files changed, 8 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hive/blob/3e68cdc9/pom.xml
----------------------------------------------------------------------
diff --git a/pom.xml b/pom.xml
index d2a5d52..0383e01 100644
--- a/pom.xml
+++ b/pom.xml
@@ -154,7 +154,7 @@
     <mockito-all.version>1.9.5</mockito-all.version>
     <mina.version>2.0.0-M5</mina.version>
     <netty.version>4.0.23.Final</netty.version>
-    <parquet.version>1.7.0</parquet.version>
+    <parquet.version>1.8.1</parquet.version>
     <pig.version>0.12.0</pig.version>
     <protobuf.version>2.5.0</protobuf.version>
     <stax.version>1.0.1</stax.version>

http://git-wip-us.apache.org/repos/asf/hive/blob/3e68cdc9/ql/src/java/org/apache/hadoop/hive/ql/io/parquet/read/DataWritableReadSupport.java
----------------------------------------------------------------------
diff --git a/ql/src/java/org/apache/hadoop/hive/ql/io/parquet/read/DataWritableReadSupport.java
b/ql/src/java/org/apache/hadoop/hive/ql/io/parquet/read/DataWritableReadSupport.java
index 8b8b92d..97f228f 100644
--- a/ql/src/java/org/apache/hadoop/hive/ql/io/parquet/read/DataWritableReadSupport.java
+++ b/ql/src/java/org/apache/hadoop/hive/ql/io/parquet/read/DataWritableReadSupport.java
@@ -225,9 +225,13 @@ public class DataWritableReadSupport extends ReadSupport<ArrayWritable>
{
       contextMetadata.put(HIVE_TABLE_AS_PARQUET_SCHEMA, tableSchema.toString());
 
       List<Integer> indexColumnsWanted = ColumnProjectionUtils.getReadColumnIDs(configuration);
-      MessageType requestedSchemaByUser = getSchemaByIndex(tableSchema, columnNamesList,
indexColumnsWanted);
-
-      return new ReadContext(requestedSchemaByUser, contextMetadata);
+      if (!ColumnProjectionUtils.isReadAllColumns(configuration) && !indexColumnsWanted.isEmpty())
{
+        MessageType requestedSchemaByUser =
+            getSchemaByIndex(tableSchema, columnNamesList, indexColumnsWanted);
+        return new ReadContext(requestedSchemaByUser, contextMetadata);
+      } else {
+        return new ReadContext(tableSchema, contextMetadata);
+      }
     } else {
       contextMetadata.put(HIVE_TABLE_AS_PARQUET_SCHEMA, fileSchema.toString());
       return new ReadContext(fileSchema, contextMetadata);


Mime
View raw message