#50307 Ticket 50305 - Revise CleanAllRUV task restart process
Closed by spichugi. Opened by mreynolds.
mreynolds/389-ds-base ticket50305  into  master

Download 50307.patch

Bug Description:
If the server was stopped while a CleanAllRUV task was
running the task gets marked in the replica config entry
so it knowns to resume the task at server startup. The
problem is that when it resumed it just fires off the
task thread, and did not create a new Slapi_Task entry.
This makes it impossible to track these tasks that got
resumed.

Fix Description:

              There were a few things wrong with the resume process,
              including it was harded coded to only handle a maximum
              of 4 tasks.  We also were not recording all the required
              information needed to resume the task.
              Now "resume" process can handle an infinite number of
              tasks, and it creates fresh Slapi_Task entries so the
              tasks can be tracked.

CI tested & ASAN approved

https://pagure.io/389-ds-base/issue/50305

rebased onto f632ada822c7ffa6dba630a5c502dd7bdedc2f1f

from what

why do you need the unused param

why do you need the unused param

@lkrispen, this is there because that function is now passed to slapi_eq_once(). Since it unused I guess it could removed from the API, but that would be a different issue.

@lkrispen made this suggestion:

Just thinking about it, wouldn't it be an option that the task entry survives until it is completed and written to the dse.ldif at shutdown, so at startup tasks could be resumed from the task entry not from params in the repl entry ?

I thought this would work and would be a great idea, but sadly we can not use it. As the cleanallruv task is propagated among the replicas, there is only one "task". That task sends special extended operations to all the replicas (not tasks). So if a replica is stopped that only received the extended op (cleanAllRUV op) , then there is no task entry. So there is nothing to resume at start up. So for now we need to keep the current design.

good point, ack

rebased onto d08f7eb688102cd54bbacd009d162f0cc16cd5fe

Pull-Request has been merged by mreynolds

389-ds-base is moving from Pagure to Github. This means that new issues and pull requests
will be accepted only in 389-ds-base's github repository.

This pull request has been cloned to Github as issue and is available here:
- https://github.com/389ds/389-ds-base/issues/3366

If you want to continue to work on the PR, please navigate to the github issue,
download the patch from the attachments and file a new pull request.

Thank you for understanding. We apologize for all inconvenience.

Pull-Request has been closed by spichugi

Metadata