Blame SOURCES/0056-BE-Schedule-the-refresh-interval-from-the-finish-tim.patch

5fca41
From 873c9417fefc0ce7ce02f4fe4fd3b858b9b1781b Mon Sep 17 00:00:00 2001
5fca41
From: Jakub Hrozek <jhrozek@redhat.com>
5fca41
Date: Wed, 19 Jun 2019 22:03:16 +0200
5fca41
Subject: [PATCH 56/64] BE: Schedule the refresh interval from the finish time
5fca41
 of the last run
5fca41
5fca41
Related: https://pagure.io/SSSD/sssd/issue/4012
5fca41
5fca41
Changes scheduling the periodical task so that the next run is started
5fca41
relative to the previous run finish time, not start time to protect
5fca41
against cases where the refresh would take too long and run practically
5fca41
all the time.
5fca41
5fca41
Reviewed-by: Sumit Bose <sbose@redhat.com>
5fca41
(cherry picked from commit 576f3691a2d22322b08fb55fe74899d2ea4975d6)
5fca41
5fca41
Reviewed-by: Sumit Bose <sbose@redhat.com>
5fca41
---
5fca41
 src/providers/be_refresh.c | 2 +-
5fca41
 1 file changed, 1 insertion(+), 1 deletion(-)
5fca41
5fca41
diff --git a/src/providers/be_refresh.c b/src/providers/be_refresh.c
5fca41
index 50b023c3d..a9d4295ec 100644
5fca41
--- a/src/providers/be_refresh.c
5fca41
+++ b/src/providers/be_refresh.c
5fca41
@@ -157,7 +157,7 @@ errno_t be_refresh_ctx_init(struct be_ctx *be_ctx,
5fca41
     if (refresh_interval > 0) {
5fca41
         ret = be_ptask_create(be_ctx, be_ctx, refresh_interval, 30, 5, 0,
5fca41
                               refresh_interval, BE_PTASK_OFFLINE_SKIP,
5fca41
-                              BE_PTASK_SCHEDULE_FROM_LAST,
5fca41
+                              BE_PTASK_SCHEDULE_FROM_NOW,
5fca41
                               0,
5fca41
                               be_refresh_send, be_refresh_recv,
5fca41
                               ctx, "Refresh Records", NULL);
5fca41
-- 
5fca41
2.20.1
5fca41