Skip to main content

Module watcher

Module watcher 

Source
Available on crate features serve and triggers only.
Expand description

The Watcher trait + the supervised polling loop. A watcher never dies on a transient error: it records health, backs off, and retries until shutdown.

Constants§

MAX_BACKOFF
Backoff ceiling so a persistently-failing watcher still retries periodically.
UNHEALTHY_THRESHOLD
Consecutive poll failures before a watcher is reported unhealthy on /readyz.

Traits§

Watcher
One pollable watcher (object_arrival / queue_depth). Webhook is push, not polled, so it does not implement this.

Functions§

backoff
Exponential backoff doubling from base (the poll interval) to MAX_BACKOFF.
run_supervised
Run a watcher until shutdown fires. Never returns an error (logs instead).