X-czh commented on code in PR #27429:
URL: https://github.com/apache/flink/pull/27429#discussion_r2697655278
##########
flink-runtime/src/main/java/org/apache/flink/streaming/runtime/tasks/SystemProcessingTimeService.java:
##########
@@ -141,7 +141,7 @@ public ScheduledFuture<?> scheduleWithFixedDelay(
private ScheduledFuture<?> scheduleRepeatedly(
ProcessingTimeCallback callback, long initialDelay, long period,
boolean fixedDelay) {
final long nextTimestamp = getCurrentProcessingTime() + initialDelay;
- final Runnable task = wrapOnTimerCallback(callback, nextTimestamp,
period);
+ final Runnable task = wrapOnTimerCallback(callback, nextTimestamp,
period, fixedDelay);
Review Comment:
The initial delay is accounted when calling scheduleRepeatedly, where
nextTimestamp is initialized to getCurrentProcessingTime() + initialDelay
##########
flink-runtime/src/main/java/org/apache/flink/streaming/runtime/tasks/SystemProcessingTimeService.java:
##########
@@ -141,7 +141,7 @@ public ScheduledFuture<?> scheduleWithFixedDelay(
private ScheduledFuture<?> scheduleRepeatedly(
ProcessingTimeCallback callback, long initialDelay, long period,
boolean fixedDelay) {
final long nextTimestamp = getCurrentProcessingTime() + initialDelay;
- final Runnable task = wrapOnTimerCallback(callback, nextTimestamp,
period);
+ final Runnable task = wrapOnTimerCallback(callback, nextTimestamp,
period, fixedDelay);
Review Comment:
Sure
--
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]