MarkGaox commented on code in PR #2886:
URL: https://github.com/apache/helix/pull/2886#discussion_r1731588044
##########
helix-rest/src/main/java/org/apache/helix/rest/clusterMaintenanceService/MaintenanceManagementService.java:
##########
@@ -472,9 +472,15 @@ private MaintenanceManagementInstanceInfo
takeFreeSingleInstanceHelper(String cl
private List<String> batchHelixInstanceStoppableCheck(String clusterId,
Collection<String> instances, Map<String, StoppableCheck>
finalStoppableChecks,
Set<String> toBeStoppedInstances) {
+
+ // Perform all but min_active replicas check in parallel
Map<String, Future<StoppableCheck>> helixInstanceChecks =
instances.stream().collect(
Collectors.toMap(Function.identity(), instance -> POOL.submit(
() -> performHelixOwnInstanceCheck(clusterId, instance,
toBeStoppedInstances))));
+
+ // Perform min_active replicas check sequentially
+ addInstanceMinActiveReplicaCheck(helixInstanceChecks,
toBeStoppedInstances);
Review Comment:
Sounds good, let's keep the current order. What do you think about adding
this check to the filterInstancesForNextCheck() method? Otherwise, we would end
up with two identical methods, which seems redundant.
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]