You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@unomi.apache.org by "Kevan Jahanshahi (Jira)" <ji...@apache.org> on 2023/05/03 16:09:00 UTC

[jira] [Updated] (UNOMI-761) Fix segment update scheduled task timing

     [ https://issues.apache.org/jira/browse/UNOMI-761?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Kevan Jahanshahi updated UNOMI-761:
-----------------------------------
    Fix Version/s: unomi-2.3.0
                   unomi-1.9.0

> 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
>             Fix For: unomi-2.3.0, unomi-1.9.0
>
>          Time Spent: 20m
>  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)