[
https://issues.apache.org/jira/browse/UNOMI-761?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17718505#comment-17718505
]
Kevan Jahanshahi commented on UNOMI-761:
----------------------------------------
PR: [https://github.com/apache/unomi/pull/613]
> Fix segment update scheduled task timing
> ----------------------------------------
>
> Key: UNOMI-761
> URL: https://issues.apache.org/jira/browse/UNOMI-761
> Project: Apache Unomi
> Issue Type: Bug
> Reporter: David Griffon
> Assignee: Kevan Jahanshahi
> Priority: Major
> Time Spent: 10m
> Remaining Estimate: 0h
>
> Currently the default schedule (at 5am each day) for segment update is not
> triggered properly, this task to fix it
> the following code
> {code}
> long initialDelay =
> SchedulerServiceImpl.getTimeDiffInSeconds(dailyDateExprEvaluationHourUtc,
> ZonedDateTime.now(ZoneOffset.UTC));
> logger.info("daily recalculation job for segments and scoring that
> contains date relative conditions will run at fixed rate, initialDelay={},
> taskExecutionPeriod={}", initialDelay, TimeUnit.DAYS.toSeconds(1));
>
> schedulerService.getScheduleExecutorService().scheduleAtFixedRate(task,
> initialDelay, taskExecutionPeriod, TimeUnit.DAYS);
> {code}
> do not compute {{initialDelay}} properly as the Unit use for the schedule is
> {{TimeUnit.DAYS}}
> This task to fix it
--
This message was sent by Atlassian Jira
(v8.20.10#820010)