dasahcc commented on a change in pull request #417: Move partition health check 
method into dataAccessor layer
URL: https://github.com/apache/helix/pull/417#discussion_r314536623
 
 

 ##########
 File path: 
helix-rest/src/main/java/org/apache/helix/rest/server/service/InstanceServiceImpl.java
 ##########
 @@ -234,8 +235,7 @@ private StoppableCheck performCustomInstanceCheck(String 
clusterId, String insta
 
   private Map<String, StoppableCheck> performPartitionsCheck(List<String> 
instances,
       RESTConfig restConfig, Map<String, String> customPayLoads) {
-    //TODO: move the heavy partition health preparation in separate class
-    PartitionHealth clusterPartitionsHealth = 
generatePartitionHealthMapFromZK();
+    PartitionHealth clusterPartitionsHealth = 
_dataAccessor.getPartitionHealthFromZK();
     // update the health status for those expired partitions on instances
     Map<String, List<String>> expiredPartitionsByInstance =
 
 Review comment:
   I think we need to move this part as well. This is also part of read 
operation. We prefer to encapsulate the read logic (ZK read + direct API call) 
to one place.

----------------------------------------------------------------
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

---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscr...@helix.apache.org
For additional commands, e-mail: reviews-h...@helix.apache.org

Reply via email to