yunfengzhou-hub commented on code in PR #20752: URL: https://github.com/apache/flink/pull/20752#discussion_r962683494
########## flink-runtime/src/main/java/org/apache/flink/runtime/operators/coordination/SubtaskGatewayImpl.java: ########## @@ -63,13 +67,11 @@ class SubtaskGatewayImpl implements OperatorCoordinator.SubtaskGateway { private final IncompleteFuturesTracker incompleteFuturesTracker; - private final List<BlockedEvent> blockedEvents; + private final TreeMap<Long, List<BlockedEvent>> blockedEventsMap; - private long currentCheckpointId; + private long latestActiveCheckpointId; Review Comment: `latestActiveCheckpointId` is used to make sure that the `checkpointId` passed to `tryCloseGateway(long)` is the same as that in the previous invocation of `markForCheckpoint(long)`. As a result, `latestActiveCheckpointId` is written when `markForCheckpoint(long)` is invoked, while the corresponding entry is added to `blockedEventsMap` when `tryCloseGateway(long)` is invoked. Given this use case, I would prefer to keep this variable. -- 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-unsubscr...@flink.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org