DmKryukov commented on code in PR #5742: URL: https://github.com/apache/hive/pull/5742#discussion_r2041702822
########## llap-client/src/java/org/apache/hadoop/hive/llap/registry/impl/LlapFixedRegistryImpl.java: ########## @@ -257,7 +257,7 @@ public List<LlapServiceInstance> getAllInstancesOrdered(boolean consistentIndexe Collections.sort(list, new Comparator<LlapServiceInstance>() { @Override public int compare(LlapServiceInstance o1, LlapServiceInstance o2) { - return o2.getWorkerIdentity().compareTo(o2.getWorkerIdentity()); + return o1.getWorkerIdentity().compareTo(o2.getWorkerIdentity()); Review Comment: Previously there was no order (and inconsistency instead) as o2 was compared to o2 and they are always equal. Ascending Order (o1.compareTo(o2)) Descending Order (o2.compareTo(o1)) Please let me know if descending order is expected -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: gitbox-unsubscr...@hive.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: gitbox-unsubscr...@hive.apache.org For additional commands, e-mail: gitbox-h...@hive.apache.org