From adb30c5b2f91ae4918750beb8c4df1aa2c194c9d Mon Sep 17 00:00:00 2001 From: Stefan Metzmacher Date: Tue, 20 Dec 2005 00:55:28 +0000 Subject: r12391: use the new periodic schedule system for the pull replication too metze (This used to be commit 3383568c31545a6716eb7045b56d516d507c0b4d) --- source4/wrepl_server/wrepl_periodic.c | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) (limited to 'source4/wrepl_server/wrepl_periodic.c') diff --git a/source4/wrepl_server/wrepl_periodic.c b/source4/wrepl_server/wrepl_periodic.c index 28c966879a..2cea3b8e7c 100644 --- a/source4/wrepl_server/wrepl_periodic.c +++ b/source4/wrepl_server/wrepl_periodic.c @@ -39,6 +39,9 @@ static NTSTATUS wreplsrv_periodic_run(struct wreplsrv_service *service) { NTSTATUS status; + status = wreplsrv_out_pull_run(service); + NT_STATUS_NOT_OK_RETURN(status); + status = wreplsrv_out_push_run(service); NT_STATUS_NOT_OK_RETURN(status); @@ -74,7 +77,7 @@ NTSTATUS wreplsrv_periodic_schedule(struct wreplsrv_service *service, uint32_t n /* prevent looping */ if (next_interval == 0) next_interval = 1; - next_time = timeval_current_ofs(next_interval, 0); + next_time = timeval_current_ofs(next_interval, 5000); if (service->periodic.te) { /* @@ -111,13 +114,6 @@ NTSTATUS wreplsrv_setup_periodic(struct wreplsrv_service *service) { NTSTATUS status; - /* - * TODO: this should go away, and we should do everything - * within the wreplsrv_periodic_run() - */ - status = wreplsrv_setup_out_connections(service); - NT_STATUS_NOT_OK_RETURN(status); - status = wreplsrv_periodic_schedule(service, 0); NT_STATUS_NOT_OK_RETURN(status); -- cgit