diff --git a/helix-rest/src/main/java/org/apache/helix/rest/clusterMaintenanceService/StoppableInstancesSelector.java b/helix-rest/src/main/java/org/apache/helix/rest/clusterMaintenanceService/StoppableInstancesSelector.java index b8d9a36464..8cf8bc83cb 100644 --- a/helix-rest/src/main/java/org/apache/helix/rest/clusterMaintenanceService/StoppableInstancesSelector.java +++ b/helix-rest/src/main/java/org/apache/helix/rest/clusterMaintenanceService/StoppableInstancesSelector.java @@ -84,7 +84,7 @@ public ObjectNode getStoppableInstancesInSingleZone(List instances, List zoneBasedInstance = getZoneBasedInstances(instances, _clusterTopology.toZoneMapping()); - getStoppableInstances(zoneBasedInstance, toBeStoppedInstancesSet, stoppableInstances, + populateStoppableInstances(zoneBasedInstance, toBeStoppedInstancesSet, stoppableInstances, failedStoppableInstances); processNonexistentInstances(instances, failedStoppableInstances); @@ -121,14 +121,14 @@ public ObjectNode getStoppableInstancesCrossZones(List instances, if (instanceSet.isEmpty()) { continue; } - getStoppableInstances(new ArrayList<>(instanceSet), toBeStoppedInstancesSet, stoppableInstances, + populateStoppableInstances(new ArrayList<>(instanceSet), toBeStoppedInstancesSet, stoppableInstances, failedStoppableInstances); } processNonexistentInstances(instances, failedStoppableInstances); return result; } - private void getStoppableInstances(List instances, Set toBeStoppedInstances, + private void populateStoppableInstances(List instances, Set toBeStoppedInstances, ArrayNode stoppableInstances, ObjectNode failedStoppableInstances) throws IOException { Map instancesStoppableChecks = _maintenanceService.batchGetInstancesStoppableChecks(_clusterId, instances,