CalvinKirs commented on code in PR #22707: URL: https://github.com/apache/doris/pull/22707#discussion_r1286774442
########## fe/fe-core/src/main/java/org/apache/doris/scheduler/manager/AsyncJobManager.java: ########## @@ -156,19 +156,20 @@ private void initAndSchedulerJob(Job job) { } private Long findFistExecuteTime(Long currentTimeMs, Long startTimeMs, Long intervalMs, boolean isCycleJob) { + // if job not delay, first execute time is start time if (startTimeMs != 0L && startTimeMs > currentTimeMs) { return startTimeMs; } - // if it's not cycle job and already delay, next execute time is current time - if (!isCycleJob) { + // if job already delay, first execute time is current time + if (startTimeMs != 0L && startTimeMs < currentTimeMs) { return currentTimeMs; } Review Comment: good question. If the start time has been postponed, should we execute it in the next scheduling cycle, or immediately. If the cycle is very large, such as we schedule in weeks, then the next execution may be next week. Of course this will cause an overall delay in subsequent execution cycles. This problem usually occurs when the machine is down and has not been restarted for a long time. -- 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: commits-unsubscr...@doris.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org For additional commands, e-mail: commits-h...@doris.apache.org