impala-reviews mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Dimitris Tsirogiannis (Code Review)" <ger...@cloudera.org>
Subject [Impala-ASF-CR] IMPALA-4916: Fix maintenance of set of item sets in DisjointSet.
Date Tue, 14 Feb 2017 21:19:06 GMT
Dimitris Tsirogiannis has posted comments on this change.

Change subject: IMPALA-4916: Fix maintenance of set of item sets in DisjointSet.
......................................................................


Patch Set 1:

(6 comments)

http://gerrit.cloudera.org:8080/#/c/5980/1/fe/src/main/java/org/apache/impala/common/Id.java
File fe/src/main/java/org/apache/impala/common/Id.java:

PS1, Line 40: 
haha. That was useless since the hashCode() for Integer is simply its value.


http://gerrit.cloudera.org:8080/#/c/5980/1/fe/src/main/java/org/apache/impala/util/DisjointSet.java
File fe/src/main/java/org/apache/impala/util/DisjointSet.java:

PS1, Line 41: conventional
object-quality based? maybe make it more explicit what part of the HashSet is causing the
problem.


http://gerrit.cloudera.org:8080/#/c/5980/1/fe/src/main/java/org/apache/impala/util/ReferenceHashSet.java
File fe/src/main/java/org/apache/impala/util/ReferenceHashSet.java:

PS1, Line 28: that
remove


PS1, Line 29: for storing elements that are expected to be mutated after
            :  * insertion into this set
Another way to put it is "when reference-equality is needed instead of object-equality". See
description of IdentityHashMap for ideas.


PS1, Line 55: private final class Wrapper<T> 
Add a brief comment.


PS1, Line 64: @SuppressWarnings("unchecked")
Maybe you want to add a comment on why the cast is safe and therefore  it is ok to suppress
the compiler warning.


-- 
To view, visit http://gerrit.cloudera.org:8080/5980
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I609c8795c09becd78815605ea8e82e2f99e82212
Gerrit-PatchSet: 1
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-Owner: Alex Behm <alex.behm@cloudera.com>
Gerrit-Reviewer: Dimitris Tsirogiannis <dtsirogiannis@cloudera.com>
Gerrit-Reviewer: Marcel Kornacker <marcel@cloudera.com>
Gerrit-HasComments: Yes

Mime
View raw message