> On May 6, 2020, 4:54 a.m., Jesús Camacho Rodríguez wrote:
> > ql/src/java/org/apache/hadoop/hive/ql/io/AcidUtils.java
> > Line 3153 (original), 3153 (patched)
> > <https://reviews.apache.org/r/72472/diff/1/?file=2230251#file2230251line3153>
> >
> >     Unrelated to this patch but related to compilation latency. I am not 
> > sure if it is actually possible but would be great to find a way to avoid 
> > the AST traversal (assuming this method is executed for every incoming 
> > query), since it adds to compilation latency and can become noticible for 
> > large queries.

Makes sense. I've removed the traversal for mat view rebuild. As for the 
read-only check, we can create a separate story to figure out if we can 
optimize it.


> On May 6, 2020, 4:54 a.m., Jesús Camacho Rodríguez wrote:
> > ql/src/java/org/apache/hadoop/hive/ql/io/AcidUtils.java
> > Lines 3165 (patched)
> > <https://reviews.apache.org/r/72472/diff/1/?file=2230251#file2230251line3166>
> >
> >     LGTM. Have you confirmed that you need the traversal and that 
> > TOK_ALTER_MATERIALIZED_VIEW_REBUILD is not the root (I am not sure about 
> > this)?
> >     
> >     Also wanted to mention. MV rebuild is translated internally into INSERT 
> > OVERWRITE, INSERT, or MERGE statements, depending on the MV semantics. 
> > Setting this TxnType to MATER_VIEW_REBUILD will not have any kind of side 
> > effect on those operations. Is that correct?

Good point, I've rechecked and we can use the root token instead of a traversal 
- updated the diff. 
This should not cause any side effects, as behaviour is only branched off for 
read-only txn types.


- Marton


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/72472/#review220647
-----------------------------------------------------------


On May 5, 2020, 8:58 a.m., Marton Bod wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/72472/
> -----------------------------------------------------------
> 
> (Updated May 5, 2020, 8:58 a.m.)
> 
> 
> Review request for hive, Denys Kuzmenko, Jesús Camacho Rodríguez, and Peter 
> Vary.
> 
> 
> Repository: hive-git
> 
> 
> Description
> -------
> 
> Introduces a new TxnType for materialization view rebuilds, and only issues 
> rebuild lock delete calls during commit for that specific type
> 
> 
> Diffs
> -----
> 
>   ql/src/java/org/apache/hadoop/hive/ql/io/AcidUtils.java 998c05e37d 
>   ql/src/test/org/apache/hadoop/hive/ql/parse/TestParseUtils.java e91a7ed760 
>   
> standalone-metastore/metastore-common/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/TxnType.java
>  349f37f914 
>   
> standalone-metastore/metastore-common/src/gen/thrift/gen-php/metastore/Types.php
>  e4b0bc726c 
>   
> standalone-metastore/metastore-common/src/gen/thrift/gen-py/hive_metastore/ttypes.py
>  1a0fee319b 
>   
> standalone-metastore/metastore-common/src/gen/thrift/gen-rb/hive_metastore_types.rb
>  e6224ec16f 
>   standalone-metastore/metastore-common/src/main/thrift/hive_metastore.thrift 
> 8462b3d7a3 
>   
> standalone-metastore/metastore-server/src/main/java/org/apache/hadoop/hive/metastore/txn/TxnHandler.java
>  8fded608d0 
> 
> 
> Diff: https://reviews.apache.org/r/72472/diff/2/
> 
> 
> Testing
> -------
> 
> 
> Thanks,
> 
> Marton Bod
> 
>

Reply via email to