parquet-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ga...@apache.org
Subject [parquet-mr] branch master updated: PARQUET-1514: ParquetFileWriter Records Compressed Bytes instead of Uncompressed Bytes (#607)
Date Wed, 06 Feb 2019 09:21:09 GMT
This is an automated email from the ASF dual-hosted git repository.

gabor pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/parquet-mr.git


The following commit(s) were added to refs/heads/master by this push:
     new 5bd1265  PARQUET-1514: ParquetFileWriter Records Compressed Bytes instead of Uncompressed
Bytes (#607)
5bd1265 is described below

commit 5bd126557cdbfccef9d0b282230cdd671c003c4f
Author: BELUGABEHR <BELUGABEHR@users.noreply.github.com>
AuthorDate: Wed Feb 6 04:20:59 2019 -0500

    PARQUET-1514: ParquetFileWriter Records Compressed Bytes instead of Uncompressed Bytes
(#607)
---
 .../src/main/java/org/apache/parquet/hadoop/ParquetFileWriter.java  | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/parquet-hadoop/src/main/java/org/apache/parquet/hadoop/ParquetFileWriter.java
b/parquet-hadoop/src/main/java/org/apache/parquet/hadoop/ParquetFileWriter.java
index 5d4f6b7..6158dad 100644
--- a/parquet-hadoop/src/main/java/org/apache/parquet/hadoop/ParquetFileWriter.java
+++ b/parquet-hadoop/src/main/java/org/apache/parquet/hadoop/ParquetFileWriter.java
@@ -850,7 +850,7 @@ public class ParquetFileWriter {
     // copy the data for all chunks
     long start = -1;
     long length = 0;
-    long blockCompressedSize = 0;
+    long blockUncompressedSize = 0L;
     for (int i = 0; i < columnsInOrder.size(); i += 1) {
       ColumnChunkMetaData chunk = columnsInOrder.get(i);
 
@@ -891,10 +891,10 @@ public class ParquetFileWriter {
           chunk.getTotalSize(),
           chunk.getTotalUncompressedSize()));
 
-      blockCompressedSize += chunk.getTotalSize();
+      blockUncompressedSize += chunk.getTotalUncompressedSize();
     }
 
-    currentBlock.setTotalByteSize(blockCompressedSize);
+    currentBlock.setTotalByteSize(blockUncompressedSize);
 
     endBlock();
   }


Mime
View raw message