JunRuiLee commented on code in PR #24025:
URL: https://github.com/apache/flink/pull/24025#discussion_r1451892446
##########
flink-tests/src/test/java/org/apache/flink/test/checkpointing/CheckpointAfterAllTasksFinishedITCase.java:
##########
@@ -82,7 +83,8 @@ public void setUp() {
@Test
public void testImmediateCheckpointing() throws Exception {
env.setRestartStrategy(RestartStrategies.noRestart());
- env.enableCheckpointing(Long.MAX_VALUE - 1);
+ env.enableCheckpointing(
+ Duration.ofNanos(Long.MAX_VALUE /* max allowed by FLINK
*/).toMillis());
Review Comment:
1. The previous use of Long.MAX_VALUE - 1 as the checkpoint interval was
intentional because using Long.MAX_VALUE itself would effectively disable
checkpointing, which isn't the desired behavior. The intention was to enable
checkpointing with an interval so large that it effectively prevents any
checkpoint from being triggered during the test run. The use of
Duration.ofNanos(Long.MAX_VALUE).toMillis() aligns well with this scenario.
2. I will review all instances where a large checkpoint interval is used and
add comments to clarify the reason using these intervals.
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]