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

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

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

    https://github.com/apache/tajo/pull/618#discussion_r33785085
  
    --- Diff: 
tajo-plan/src/main/java/org/apache/tajo/plan/logical/AlterTableNode.java ---
    @@ -124,16 +155,18 @@ public PlanString getPlanString() {
     
       @Override
       public int hashCode() {
    -    final int prime = 31;
    -    int result = 1;
    -    result = prime * result + ((addNewColumn == null) ? 0 : 
addNewColumn.hashCode());
    -    result = prime * result + ((alterTableOpType == null) ? 0 : 
alterTableOpType.hashCode());
    -    result = prime * result + ((columnName == null) ? 0 : 
columnName.hashCode());
    -    result = prime * result + ((newColumnName == null) ? 0 : 
newColumnName.hashCode());
    -    result = prime * result + ((newTableName == null) ? 0 : 
newTableName.hashCode());
    -    result = prime * result + ((tableName == null) ? 0 : 
tableName.hashCode());
    -    result = prime * result + ((properties == null) ? 0 : 
properties.hashCode());
    -    return result;
    +    return Objects.hashCode(tableName,
    +      null != addNewColumn ? Objects.hashCode(addNewColumn) : addNewColumn,
    --- End diff --
    
    Objects.hashCode() allows null parameters, so this null checking is 
unnecessary. 
    Anyway, I think that the former way is more efficient than using 
Objects.hashCode(). 
    However, I also know that most hashCode() methods are written using 
Objects.hashCode(). So,  we may need to improve those hashCode() methods when 
the performance issue arises later.


> Implement logical plan part and DDL executor for alter partition.
> -----------------------------------------------------------------
>
>                 Key: TAJO-1345
>                 URL: https://issues.apache.org/jira/browse/TAJO-1345
>             Project: Tajo
>          Issue Type: Sub-task
>          Components: planner/optimizer
>            Reporter: Jaehwa Jung
>            Assignee: Jaehwa Jung
>             Fix For: 0.11.0
>
>         Attachments: TAJO-1345.patch
>
>
> See the title. The main objective of this issue is to implement the logical 
> planning part and the DDL executor part for alter table partition support.



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

Reply via email to