Tachograph auto-download scheduler improvements
We have reworked the retry logic of the automatic tachograph file download scheduler (the auto_file_request configuration in the device settings).
What changed:
1. Failed downloads no longer delay the next attempt by the full interval.
Previously, under certain error conditions a failed download attempt could be treated as a completed one, postponing the next attempt for the whole configured interval (which can be many hours or days). Now the configured interval only advances after a successfully stored file — any failure keeps the file type on the fast retry track.
2. Retries now use progressive backoff instead of a fixed delay.
Failed attempts are retried after 10 minutes, then 20, 30, and at most every 60 minutes for persistently failing downloads. This keeps retries responsive for transient issues (temporary connectivity problems, tachograph busy) while not hammering the vehicle and the shared company card every 10 minutes when the problem is persistent (hardware issues, card used by another vehicle). The first successful download resets the backoff.
3. One problematic file type no longer blocks the others.
If a download request gets no response at all (for example, the tracker lost connectivity right after the request), the scheduler now moves on to the next configured file type once the retry delay elapses, and re-queues the silent type at the end of the line. Previously such a "hanging" type could keep retrying itself indefinitely while other configured types (driver cards, memory) waited without any chance to download.
4. Better error handling for Ruptela tachograph downloads.
Authentication and communication errors reported by Ruptela devices now immediately finish the download command with a failure result (visible in the device commands/logs) instead of leaving it pending. The next attempt is then scheduled by the retry backoff described above.
No configuration changes are required — everything applies automatically to devices with tachograph auto-download configured.