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

ASF GitHub Bot commented on TAJO-2174:
--------------------------------------

Github user jinossy commented on a diff in the pull request:

    https://github.com/apache/tajo/pull/1047#discussion_r76527398
  
    --- Diff: 
tajo-catalog/tajo-catalog-drivers/tajo-hive/src/main/java/org/apache/tajo/catalog/store/HiveCatalogStore.java
 ---
    @@ -789,6 +793,44 @@ private void dropPartition(String databaseName, String 
tableName, CatalogProtos.
         }
       }
     
    +  private void setProperties(final String databaseName, final String 
tableName,
    +                             final PrimitiveProtos.KeyValueSetProto 
properties) {
    +    HiveCatalogStoreClientPool.HiveCatalogStoreClient client = null;
    +    try {
    +      client = clientPool.getClient();
    +      Table table = client.getHiveClient().getTable(databaseName, 
tableName);
    +      table.getParameters().putAll(ProtoUtil.convertToMap(properties));
    +       client.getHiveClient().alter_table(databaseName, tableName, table);
    +    } catch (NoSuchObjectException nsoe) {
    +    } catch (Exception e) {
    +      throw new TajoInternalError(e);
    +    } finally {
    +      if (client != null) {
    +        client.release();
    +      }
    +    }
    +  }
    +
    +  private void unsetProperties(final String databaseName, final String 
tableName,
    +                               PrimitiveProtos.StringListProto 
propertyKeys) {
    +    HiveCatalogStoreClientPool.HiveCatalogStoreClient client = null;
    +    try {
    +      client = clientPool.getClient();
    +      Table table = client.getHiveClient().getTable(databaseName, 
tableName);
    +       for (String propertyKey : ProtoUtil.convertStrings(propertyKeys)) {
    --- End diff --
    
    please fix indentation


> Implement HiveCatalogStore#alterTable
> -------------------------------------
>
>                 Key: TAJO-2174
>                 URL: https://issues.apache.org/jira/browse/TAJO-2174
>             Project: Tajo
>          Issue Type: Sub-task
>            Reporter: Lee Dongjin
>            Assignee: Lee Dongjin
>
> The case of SET_PROPERTY and UNSET_PROPERTY are missing.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to