NealSun96 commented on a change in pull request #1468:
URL: https://github.com/apache/helix/pull/1468#discussion_r513846668
##########
File path:
helix-core/src/main/java/org/apache/helix/task/FixedTargetTaskAssignmentCalculator.java
##########
@@ -123,6 +124,17 @@ public
FixedTargetTaskAssignmentCalculator(AssignableInstanceManager assignableI
return taskPartitions;
}
+ @Override
+ public Set<Integer> getRemovedPartitions(JobConfig jobConfig, JobContext
jobContext, Set<Integer> allPartitions) {
+ Set<Integer> deletedPartitions = new HashSet<>();
+ for (Integer partition : jobContext.getPartitionSet()) {
+ if (!allPartitions.contains(partition)) {
+ deletedPartitions.add(partition);
+ }
+ }
+ return deletedPartitions;
Review comment:
nit: can probably be condensed to one line.
----------------------------------------------------------------
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:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]