kl0u commented on a change in pull request #9131: [FLINK-12858][checkpointing] 
Stop-with-savepoint, workaround: fail whole job when savepoint is declined by a 
task
URL: https://github.com/apache/flink/pull/9131#discussion_r304832210
 
 

 ##########
 File path: 
flink-runtime/src/main/java/org/apache/flink/runtime/scheduler/LegacyScheduler.java
 ##########
 @@ -649,4 +658,24 @@ private String 
retrieveTaskManagerLocation(ExecutionAttemptID executionAttemptID
                        .map(TaskManagerLocation::toString)
                        .orElse("Unknown location");
        }
+
+       private static boolean isPotentiallyTaskLocalException(Throwable 
throwable) {
 
 Review comment:
   This method is pretty fragile. As soon as someone adds another exception, it 
may break. So I would suggest to add a flag in the `CheckpointFailureReason`, 
something like `final boolean preFlight`, that is set in the constructor and 
indicates if the exception at hand was thrown before the checkpoint barrier was 
emitted to the job (pre-flight), or not. This way, every new exception will 
have to set the flag and we can have in this method simply something like 
`isPreFlight()` which will check at which stage the exception was thrown.

----------------------------------------------------------------
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]


With regards,
Apache Git Services

Reply via email to