You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "huwh (via GitHub)" <gi...@apache.org> on 2023/02/21 06:07:23 UTC

[GitHub] [flink] huwh commented on a diff in pull request #21970: [FLINK-31041][runtime] Fix multiple restoreState when GlobalFailure occurs in a short period.

huwh commented on code in PR #21970:
URL: https://github.com/apache/flink/pull/21970#discussion_r1112580326


##########
flink-runtime/src/main/java/org/apache/flink/runtime/scheduler/DefaultScheduler.java:
##########
@@ -377,6 +377,10 @@ private void restartTasks(
         final Set<ExecutionVertexID> verticesToRestart =
                 executionVertexVersioner.getUnmodifiedExecutionVertices(executionVertexVersions);
 
+        if (verticesToRestart.isEmpty()) {
+            return;

Review Comment:
   There are three functions will be skipped after this change:
   1. OperatorCoordinatorHolder#resetToCheckpoint
   2. CheckpointCoordinator#abortPendingCheckpoints
   3. MasterHooks#reset/restore
   
   But those will be invoked later(new global failure) with the newest checkpoint-id. So i think this change is safe.



-- 
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: issues-unsubscribe@flink.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org