pnowojski commented on a change in pull request #10332:
[FLINK-13905][checkpointing] Separate checkpoint triggering into several
asynchronous stages
URL: https://github.com/apache/flink/pull/10332#discussion_r363079598
##########
File path:
flink-runtime/src/main/java/org/apache/flink/runtime/checkpoint/CheckpointCoordinator.java
##########
@@ -1262,11 +1261,19 @@ public void stopCheckpointScheduler() {
*/
public void abortPendingCheckpoints(CheckpointException exception) {
synchronized (lock) {
- for (PendingCheckpoint p : pendingCheckpoints.values())
{
- failPendingCheckpoint(p,
exception.getCheckpointFailureReason());
- }
+ // do not traverse pendingCheckpoints directly, because
it might be changed
+ abortPendingCheckpoints(
+ pendingCheckpoints.values().toArray(new
PendingCheckpoint[0]), exception);
+ }
+ }
+
+ private void abortPendingCheckpoints(
+ PendingCheckpoint[] checkpoints, CheckpointException exception)
{
Review comment:
nit: if one parameter is indented, all of them should be (according to our
code style)
----------------------------------------------------------------
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