]> git.proxmox.com Git - proxmox-backup.git/commit
file-restore-daemon: watchdog: add inhibit for long downloads
authorStefan Reiter <s.reiter@proxmox.com>
Thu, 6 May 2021 15:26:21 +0000 (17:26 +0200)
committerThomas Lamprecht <t.lamprecht@proxmox.com>
Tue, 25 May 2021 09:56:43 +0000 (11:56 +0200)
commit1fde4167eaedb98a6ce34e48d3f2f531ce4d58be
tree7c72b2fd34fb161a87bd4cf48e4d6f5c1f4decf4
parent75f9f40922f9c5380336b987519d9d46d5b6db03
file-restore-daemon: watchdog: add inhibit for long downloads

The extract API call may be active for more than the watchdog timeout,
so a simple ping is not enough.

This adds an "inhibit" API, which will stop the watchdog from completing
as long as at least one WatchdogInhibitor instance is alive. Keep one in
the download task, so it will be dropped once it completes (or errors).

Signed-off-by: Stefan Reiter <s.reiter@proxmox.com>
src/bin/proxmox_restore_daemon/api.rs
src/bin/proxmox_restore_daemon/watchdog.rs