From dev-return-146118-archive-asf-public=cust-asf.ponee.io@hive.apache.org Tue Feb 6 08:06:48 2018 Return-Path: X-Original-To: archive-asf-public@eu.ponee.io Delivered-To: archive-asf-public@eu.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by mx-eu-01.ponee.io (Postfix) with ESMTP id 08C2E180657 for ; Tue, 6 Feb 2018 08:06:48 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id EC405160C45; Tue, 6 Feb 2018 07:06:47 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 1B09D160C3A for ; Tue, 6 Feb 2018 08:06:46 +0100 (CET) Received: (qmail 94629 invoked by uid 500); 6 Feb 2018 07:06:45 -0000 Mailing-List: contact dev-help@hive.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@hive.apache.org Delivered-To: mailing list dev@hive.apache.org Received: (qmail 94618 invoked by uid 99); 6 Feb 2018 07:06:45 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd4-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 06 Feb 2018 07:06:45 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd4-us-west.apache.org (ASF Mail Server at spamd4-us-west.apache.org) with ESMTP id BAB49C0047; Tue, 6 Feb 2018 07:06:44 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 0.69 X-Spam-Level: X-Spam-Status: No, score=0.69 tagged_above=-999 required=6.31 tests=[HTML_MESSAGE=2, KAM_LAZY_DOMAIN_SECURITY=1, RCVD_IN_DNSWL_MED=-2.3, T_RP_MATCHES_RCVD=-0.01] autolearn=disabled Received: from mx1-lw-us.apache.org ([10.40.0.8]) by localhost (spamd4-us-west.apache.org [10.40.0.11]) (amavisd-new, port 10024) with ESMTP id tbFUf-KKy0VP; Tue, 6 Feb 2018 07:06:42 +0000 (UTC) Received: from mailrelay1-us-west.apache.org (mailrelay1-us-west.apache.org [209.188.14.139]) by mx1-lw-us.apache.org (ASF Mail Server at mx1-lw-us.apache.org) with ESMTP id 84DC75F125; Tue, 6 Feb 2018 07:06:42 +0000 (UTC) Received: from reviews.apache.org (unknown [10.41.0.12]) by mailrelay1-us-west.apache.org (ASF Mail Server at mailrelay1-us-west.apache.org) with ESMTP id 1F2BEE0149; Tue, 6 Feb 2018 07:06:42 +0000 (UTC) Received: from reviews-vm2.apache.org (localhost [IPv6:::1]) by reviews.apache.org (ASF Mail Server at reviews-vm2.apache.org) with ESMTP id 4C0C0C400F6; Tue, 6 Feb 2018 07:06:40 +0000 (UTC) Content-Type: multipart/alternative; boundary="===============0811641321675025449==" MIME-Version: 1.0 Subject: Re: Review Request 65478: HIVE-18553 VectorizedParquetReader fails after adding a new column to table From: Vihang Karajgaonkar via Review Board To: Vihang Karajgaonkar , hive , cheng xu Date: Tue, 06 Feb 2018 07:06:40 -0000 Message-ID: <20180206070640.26832.10076@reviews-vm2.apache.org> X-ReviewBoard-URL: https://reviews.apache.org/ Auto-Submitted: auto-generated Sender: Vihang Karajgaonkar X-ReviewGroup: hive X-Auto-Response-Suppress: DR, RN, OOF, AutoReply X-ReviewRequest-URL: https://reviews.apache.org/r/65478/ X-Sender: Vihang Karajgaonkar References: <20180205084603.45644.52776@reviews-vm2.apache.org> In-Reply-To: <20180205084603.45644.52776@reviews-vm2.apache.org> X-ReviewBoard-Diff-For: ql/src/test/results/clientpositive/schema_evol_par_vec_table.q.out X-ReviewBoard-Diff-For: ql/src/java/org/apache/hadoop/hive/ql/io/parquet/vector/VectorizedDummyColumnReader.java X-ReviewBoard-Diff-For: ql/src/java/org/apache/hadoop/hive/ql/io/parquet/vector/ParquetDataColumnReaderFactory.java X-ReviewBoard-Diff-For: ql/src/test/queries/clientpositive/schema_evol_par_vec_table.q Reply-To: Vihang Karajgaonkar X-ReviewRequest-Repository: hive-git --===============0811641321675025449== MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/65478/#review196867 ----------------------------------------------------------- ql/src/java/org/apache/hadoop/hive/ql/io/parquet/vector/ParquetDataColumnReaderFactory.java Lines 114 (patched) nit, It should probably say "Implementation is consistent with .." Same with TypesFromInt64PageReader and TypesFromFloatPageReader below. Thanks ql/src/test/queries/clientpositive/schema_evol_par_vec_table.q Lines 9 (patched) Does this test work when dictionary encoding is both enabled/disabled? You can change parquet dictionary encoding by setting table property "parquet.enable.dictionary"="true" or "false". Can you please modify the test to include that as well? ql/src/test/queries/clientpositive/schema_evol_par_vec_table.q Lines 49 (patched) I think this comment can be removed now so that there is no confusion in the future. ql/src/test/queries/clientpositive/schema_evol_par_vec_table.q Lines 71 (patched) Can you please test using timestamps as well. Specifically, the following should work. drop table test_alter2; create table test_alter2 (ts timestamp) stored as parquet; insert into test_alter2 values ('2018-01-01 13:14:15.123456'), ('2018-01-02 14:15:16.123456'), ('2018-01-03 16:17:18.123456'); select * from test_alter2; alter table test_alter2 replace columns (ts string); select * from test_alter2; drop table test_alter2; create table test_alter2 (ts timestamp) stored as parquet; insert into test_alter2 values ('2018-01-01 13:14:15.123456'), ('2018-01-02 14:15:16.123456'), ('2018-01-03 16:17:18.123456'); select * from test_alter2; alter table test_alter2 replace columns (ts varchar(19)); -- this should truncate the microseconds select * from test_alter2; drop table test_alter2; create table test_alter2 (ts timestamp) stored as parquet; insert into test_alter2 values ('2018-01-01 13:14:15.123456'), ('2018-01-02 14:15:16.123456'), ('2018-01-03 16:17:18.123456'); select * from test_alter2; alter table test_alter2 replace columns (ts char(25); select * from test_alter2; - Vihang Karajgaonkar On Feb. 5, 2018, 8:46 a.m., cheng xu wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/65478/ > ----------------------------------------------------------- > > (Updated Feb. 5, 2018, 8:46 a.m.) > > > Review request for hive. > > > Repository: hive-git > > > Description > ------- > > VectorizedParquetReader throws an exception when trying to reading from a parquet table on which new columns are added. > > > Diffs > ----- > > ql/src/java/org/apache/hadoop/hive/ql/io/parquet/vector/BaseVectorizedColumnReader.java 907a9b8 > ql/src/java/org/apache/hadoop/hive/ql/io/parquet/vector/ParquetDataColumnReaderFactory.java PRE-CREATION > ql/src/java/org/apache/hadoop/hive/ql/io/parquet/vector/VectorizedDummyColumnReader.java PRE-CREATION > ql/src/java/org/apache/hadoop/hive/ql/io/parquet/vector/VectorizedParquetRecordReader.java 08ac57b > ql/src/test/org/apache/hadoop/hive/ql/io/parquet/TestVectorizedColumnReader.java 9e414dc > ql/src/test/org/apache/hadoop/hive/ql/io/parquet/VectorizedColumnReaderTestBase.java 5d3ebd6 > ql/src/test/queries/clientpositive/schema_evol_par_vec_table.q PRE-CREATION > ql/src/test/results/clientpositive/schema_evol_par_vec_table.q.out PRE-CREATION > > > Diff: https://reviews.apache.org/r/65478/diff/2/ > > > Testing > ------- > > Newly added UT passed and qtest passed locally. > > > Thanks, > > cheng xu > > --===============0811641321675025449==--