You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Tower: a cheap liveness route with the version; /health is too heavy to probe under load #1977
GET /health is Tower's heaviest read route: it builds the instance list and runs a full process census (ps) on every call. Since the fix for issue #1901 (PR #1976), every CLI command that needs Tower probes it first, and up to twice when the machine is busy, which is exactly when the census is slowest and Tower's event loop is already starved. The probe meant to tell "busy" from "down" adds to the load that makes Tower look down.
Separately, the Spec 1940 review asked for a version on a cheap route: the CLI tells an older Tower today by asking for the whole address book after a NOT_FOUND.
Ask
A liveness route that does no work: no instance list, no process census, no database read. It answers with a small fixed body that includes Tower's version (and schema version, if cheap).
The older-Tower check in afx send uses the version from the liveness route in place of the address-book probe. A Tower too old to have the route answers 404, which is itself the answer.
Tests: the liveness handler calls none of the heavy functions (spy on them); the probe reports running / not-running / unresponsive against the new route and falls back correctly against a Tower without it.
Found by the builder of PR #1976 and by the Spec 1940 review. Not urgent; it removes load from the failure path.
Activity