mirror of
https://github.com/MBombeck/HealthLog.git
synced 2026-11-07 04:12:04 +00:00
Since handlers load on their queue's first job, a module the image cannot load no longer fails the worker's boot. The worker comes up healthy, the queue burns its retries when it first has work, and a one-shot job (a restore, an import tail) ends failed with nobody told at deploy time. After binding every queue the worker now runs `preloadHandlers` in the background, without awaiting it, so readiness is unchanged. It loads each handler once through the same memoised loader its queue is bound to, so a module that loads stays loaded for the first job. Each failure is reported on the `job.run.failed` line at error, with the queue's name and `reason: "handler_load_failed"`, plus the worker error report (stderr and GlitchTip). A summary line on stderr names every queue that failed. The sweep never throws, and a failing report does not stop it. docs/ops/deploy.md says what to look for after a deploy.