hive-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Alexander Pivovarov (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (HIVE-10588) implement hashCode method for HWISessionItem
Date Mon, 04 May 2015 00:12:06 GMT

     [ https://issues.apache.org/jira/browse/HIVE-10588?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Alexander Pivovarov updated HIVE-10588:
---------------------------------------
    Description: 
HWISessionItem overwrites equals method but not hashCode method.
It violates java contract below:
"If two objects are equal according to the equals(Object) method, then calling the hashCode
method on each of the two objects must produce the same integer result."
Currently equals and compareTo methods use sessionName in their implementation.
sessionName.hashcode() can be used in HWISessionItem.hashCode as well.

> implement hashCode method for HWISessionItem
> --------------------------------------------
>
>                 Key: HIVE-10588
>                 URL: https://issues.apache.org/jira/browse/HIVE-10588
>             Project: Hive
>          Issue Type: Improvement
>          Components: Web UI
>            Reporter: Alexander Pivovarov
>            Assignee: Alexander Pivovarov
>            Priority: Minor
>
> HWISessionItem overwrites equals method but not hashCode method.
> It violates java contract below:
> "If two objects are equal according to the equals(Object) method, then calling the hashCode
method on each of the two objects must produce the same integer result."
> Currently equals and compareTo methods use sessionName in their implementation.
> sessionName.hashcode() can be used in HWISessionItem.hashCode as well.



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

Mime
View raw message