hive-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "jiraposter@reviews.apache.org (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HIVE-2188) Add multi_get_table function in Hive Metastore
Date Mon, 06 Jun 2011 21:18:59 GMT

    [ https://issues.apache.org/jira/browse/HIVE-2188?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13045121#comment-13045121
] 

jiraposter@reviews.apache.org commented on HIVE-2188:
-----------------------------------------------------



bq.  On 2011-06-03 14:04:02, Ashutosh Chauhan wrote:
bq.  > trunk/metastore/if/hive_metastore.thrift, line 249
bq.  > <https://reviews.apache.org/r/831/diff/1/?file=20144#file20144line249>
bq.  >
bq.  >     How about calling it get_multi_table instead? multi_get_table sounds little
confusing to me.

Ok, get_multi_table definitely sounds better.


bq.  On 2011-06-03 14:04:02, Ashutosh Chauhan wrote:
bq.  > trunk/metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStore.java, line
521
bq.  > <https://reviews.apache.org/r/831/diff/1/?file=20145#file20145line521>
bq.  >
bq.  >     You can write this more concisely using commons-lang utility method as: StringUtils.join(tbls,',');

Thanks for the tip; I changed this.


bq.  On 2011-06-03 14:04:02, Ashutosh Chauhan wrote:
bq.  > trunk/metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStore.java, line
1182
bq.  > <https://reviews.apache.org/r/831/diff/1/?file=20145#file20145line1182>
bq.  >
bq.  >     You can get rid of tables.get(i) == null check that will never be true.

I cleaned up the checks for seeing if the db had all the requested tables.  Also, I realized
that I did not guarantee returning tables in the same order as those requested, so I fixed
that up too.


bq.  On 2011-06-03 14:04:02, Ashutosh Chauhan wrote:
bq.  > trunk/metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStore.java, line
1195
bq.  > <https://reviews.apache.org/r/831/diff/1/?file=20145#file20145line1195>
bq.  >
bq.  >     Instead of throwing RuntimeException, create MetaException and throw that.

I changed it to throw a MetaException instead.  However, the other metastore operations (e.g.,
get_table, append_partition) throw RuntimException, which is what I based get_multi_table
off.


bq.  On 2011-06-03 14:04:02, Ashutosh Chauhan wrote:
bq.  > trunk/service/src/test/org/apache/hadoop/hive/service/TestHiveServer.java, line
221
bq.  > <https://reviews.apache.org/r/831/diff/1/?file=20148#file20148line221>
bq.  >
bq.  >     This test really belongs in the TestMetastore or some such in metastore dir
not in HiveServer.

Thanks for the pointer and for the feedback.


- Sohan


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


On 2011-06-06 21:09:54, Sohan Jain wrote:
bq.  
bq.  -----------------------------------------------------------
bq.  This is an automatically generated e-mail. To reply, visit:
bq.  https://reviews.apache.org/r/831/
bq.  -----------------------------------------------------------
bq.  
bq.  (Updated 2011-06-06 21:09:54)
bq.  
bq.  
bq.  Review request for hive, Paul Yang and Ashutosh Chauhan.
bq.  
bq.  
bq.  Summary
bq.  -------
bq.  
bq.  Created a function "multi_get_table" that retrieves multiple tables on one trip to the
hive metastore, saving round trip time.
bq.  
bq.  
bq.  This addresses bug HIVE-2188.
bq.      https://issues.apache.org/jira/browse/HIVE-2188
bq.  
bq.  
bq.  Diffs
bq.  -----
bq.  
bq.    trunk/metastore/if/hive_metastore.thrift 1130342 
bq.    trunk/metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStore.java 1130342

bq.    trunk/metastore/src/java/org/apache/hadoop/hive/metastore/ObjectStore.java 1130342

bq.    trunk/metastore/src/java/org/apache/hadoop/hive/metastore/RawStore.java 1130342 
bq.    trunk/metastore/src/test/org/apache/hadoop/hive/metastore/TestHiveMetaStore.java 1130342

bq.  
bq.  Diff: https://reviews.apache.org/r/831/diff
bq.  
bq.  
bq.  Testing
bq.  -------
bq.  
bq.  Added a test case to testMetasore() in TestHiveServer.  Also tested for speed improvements
in a client session.
bq.  
bq.  
bq.  Thanks,
bq.  
bq.  Sohan
bq.  
bq.



> Add multi_get_table function in Hive Metastore
> ----------------------------------------------
>
>                 Key: HIVE-2188
>                 URL: https://issues.apache.org/jira/browse/HIVE-2188
>             Project: Hive
>          Issue Type: New Feature
>          Components: Metastore
>            Reporter: Sohan Jain
>            Assignee: Sohan Jain
>            Priority: Minor
>         Attachments: HIVE-2188.1.patch
>
>
> This function would get multiple tables from the hive metastore as opposed to just one
at a time, saving round trip time to the metastore.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message