hive-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ashutosh Chauhan (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HIVE-16970) General Improvements To org.apache.hadoop.hive.metastore.cache.CacheUtils
Date Tue, 24 Oct 2017 23:40:00 GMT

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

Ashutosh Chauhan commented on HIVE-16970:
-----------------------------------------

+1

> General Improvements To org.apache.hadoop.hive.metastore.cache.CacheUtils
> -------------------------------------------------------------------------
>
>                 Key: HIVE-16970
>                 URL: https://issues.apache.org/jira/browse/HIVE-16970
>             Project: Hive
>          Issue Type: Improvement
>          Components: Metastore
>    Affects Versions: 3.0.0
>            Reporter: BELUGA BEHR
>            Assignee: BELUGA BEHR
>            Priority: Trivial
>         Attachments: HIVE-16970.1.patch, HIVE-16970.2.patch
>
>
> # Simplify
> # Do not initiate empty collections
> # Parsing is incorrect:
> {code:title=org.apache.hadoop.hive.metastore.cache.CacheUtils}
>   public static String buildKey(String dbName, String tableName, List<String> partVals)
{
>     String key = buildKey(dbName, tableName);
>     if (partVals == null || partVals.size() == 0) {
>       return key;
>     }
>     // missing a delimiter between the "tableName" and the first "partVal"
>     for (int i = 0; i < partVals.size(); i++) {
>       key += partVals.get(i);
>       if (i != partVals.size() - 1) {
>         key += delimit;
>       }
>     }
>     return key;
>   }
> public static Object[] splitPartitionColStats(String key) {
> // ...
> }
> {code}
> The result of passing the key to the "split" method is:
> {code}
> buildKey("db","Table",["Part1","Part2","Part3"], "col");
> [db, tablePart1, [Part2, Part3], col]
> // "table" and "Part1" is mistakenly concatenated
> {code}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Mime
View raw message