StefanRRichter commented on a change in pull request #7009: [FLINK-10712] 
Support to restore state when using RestartPipelinedRegionStrategy
URL: https://github.com/apache/flink/pull/7009#discussion_r236283201
 
 

 ##########
 File path: 
flink-runtime/src/main/java/org/apache/flink/runtime/checkpoint/StateAssignmentOperation.java
 ##########
 @@ -201,31 +261,33 @@ private void assignTaskStateToExecutionJobVertices(
 
                for (int subTaskIndex = 0; subTaskIndex < newParallelism; 
subTaskIndex++) {
 
-                       Execution currentExecutionAttempt = 
executionJobVertex.getTaskVertices()[subTaskIndex]
-                               .getCurrentExecutionAttempt();
+                       if (subTaskIndices.contains(subTaskIndex)) {
 
 Review comment:
   instead of `for i in (0 .. newParallelism) -> `contains(i)`, why not supply 
an `Iterable<Integer> subtaskIDs` instead and then `for (int subtask : 
subtaskIDs)`? The old codepath would just pass in an iterable from 0 to new 
parallelism.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to