[pbs-devel] [RFC PATCH proxmox-backup 2/2] server/worker_task: simplify task log writing
Thomas Lamprecht
t.lamprecht at proxmox.com
Wed Oct 28 18:57:48 CET 2020
On 28.10.20 10:58, Dominik Csapak wrote:
> instead of prerotating 1000 tasks
> (which resulted in 2 writes each time an active worker was finished)
> simply append finished tasks to the archive (which will be rotated)
>
> page cache should be good enough so that we can get the task logs fast
>
> since existing installations might have an 'index' file, we
> still have to read tasks from there
>
> Signed-off-by: Dominik Csapak <d.csapak at proxmox.com>
> ---
> maybe there is a better way to get rid of the index file handling?
> we cannot really simply append the index file to the archive in
> a postinst since the old daemon may still write into it..
>
> do we actually care? the users may lose some task information, but
> no actual harm should come from lost task logs, since we use
> the jobstate for the state handling and scheduling
>
> we could also simply removing the index code from the iterator
> and leave it in 'update_active_workers' so that after the next finished
> active task, we move them from the index file to archive
> so we lose them just temporarily....?
>
We may not care to much, while not ideal, we're still beta and this is not
a hard error.
The idea from above paragraph sounds somewhat OK.
In anyway, I'd do a not completely correct deprecation here, i.e., remove
backward compat stuff after 1.0, so those which update often and update relatively
soon after first stable release do not run into it and the others get some tasks
missing from the time when it was still beta.
Keeping some simple compat until after 1.0.1 or so would be OK for me, but doing
it until 2.0 is IMO to cumbersome compared to the drawbacks.
More information about the pbs-devel
mailing list