i3wangyi commented on a change in pull request #365: Fix RoutingTableProvider statePropagationLatency metric reporting bug URL: https://github.com/apache/helix/pull/365#discussion_r309462916
########## File path: helix-core/src/main/java/org/apache/helix/common/caches/AbstractDataCache.java ########## @@ -48,15 +50,17 @@ public AbstractDataCache(ControlContextProvider controlContextProvider) { * Selectively fetch Helix Properties from ZK by comparing the version of local cached one with the one on ZK. * If version on ZK is newer, fetch it from zk and update local cache. * @param accessor the HelixDataAccessor - * @param reloadKeys keys needs to be reload + * @param reloadKeysIn keys needs to be reload * @param cachedKeys keys already exists in the cache * @param cachedPropertyMap cached map of propertykey -> property object + * @param reloadKeysOut keys actually reloaded; may include more keys than reloadKeysIn * @return updated properties map */ protected Map<PropertyKey, T> refreshProperties( - HelixDataAccessor accessor, List<PropertyKey> reloadKeys, List<PropertyKey> cachedKeys, - Map<PropertyKey, T> cachedPropertyMap) { + HelixDataAccessor accessor, Set<PropertyKey> reloadKeysIn, List<PropertyKey> cachedKeys, + Map<PropertyKey, T> cachedPropertyMap, Set<PropertyKey> reloadKeysOut) { Review comment: It works like a trick and shouldn't be the right usage of Java, which only supports a single return value. The design choice of the class has some fallacies so ppl have to do hacks like this. Let's create a TODO for future refactoring works if any... ---------------------------------------------------------------- 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. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services