neiam
/vigil
public · Issues · Pulls · Labels · Forks · Compare · Actions success · Badges · Packages
⭐
Log in to mark this repository.
Slice 8: uptime and status pages
4cd4d66 · gmorell · 2026-12-02 03:16
Files changed
modified
ROADMAP.md
+14
−1
@@ -402,7 +402,7 @@ This is new: GlitchTip throws `check_in` items away.
| 402 | 402 | - Pages: the monitors list (status timeline, health, last and next run; live; inline "New monitor"), and a monitor's detail (settings, timeline, check-ins, incidents, edit, enable/disable, admin delete). The nav link reads "Crons". |
| 403 | 403 | - Tested with the real sentry-elixir 14.1 Oban cron integration, unchanged and fed Oban's job telemetry for Vigil's own MaintainWorker and EvaluateWorker: monitors appear, a missed nightly run opens an incident and alerts. Also tested with sentry-python's `@monitor` and sentry-cli 2.58 `monitors run` and `monitors list`. Vigil doesn't report its own crons to itself; that would mean adding sentry-elixir as a dependency. |
| 404 | 404 | |
| 405 | −### 8. Uptime · medium | |
| 405 | +### 8. Uptime · medium · **done** | |
| 406 | 406 | - **Monitors:** HTTP GET, HTTP POST, ping, TCP, SSL expiry, and heartbeat (push to `/api/0/organizations/{o}/heartbeat_check/{uuid}/`). |
| 407 | 407 | - **Checks:** |
| 408 | 408 | - Self-rescheduling Oban jobs in the `checks` queue. |
@@ -411,6 +411,19 @@ This is new: GlitchTip throws `check_in` items away.
| 411 | 411 | - **Alerts** on up/down changes, through slice 4. |
| 412 | 412 | - **Status pages:** public or private, slugged, live via PubSub. |
| 413 | 413 | - **Exit:** monitors flip state within one interval and alert once per change. |
| 414 | +- **As built:** | |
| 415 | + - Check types: | |
| 416 | + - `ping`: HTTP HEAD, where any answer is up, as GlitchTip's "Ping" (it isn't ICMP). | |
| 417 | + - `get` / `post`: expected status, any 2xx when unset, plus expected body, read up to 2 MB. | |
| 418 | + - `tcp`: a connection to `host:port`. | |
| 419 | + - `ssl`: a verified TLS handshake, down when the certificate expires within `ssl_warn_days`. GlitchTip only reports TLS errors. | |
| 420 | + - `heartbeat`: a push to `/api/0/organizations/{o}/heartbeat_check/{token}/`, POST or GET; down after an interval plus grace of silence. | |
| 421 | + - Every target, and every HTTP redirect hop (followed by hand, at most 5), goes through `Vigil.Outbound`, which gained `allow_private` and `check_host/2` for TCP and TLS targets. | |
| 422 | + - `CheckWorker` (queue `checks`) queues its successor before checking, one queued per monitor. The minutely `ReconcileWorker` restarts chains that stopped. | |
| 423 | + - `uptime_checks` is partitioned daily (30 days). Heartbeats that are up and change nothing aren't stored. A flip alerts once through rules of the new kind `:uptime`; the first result alerts only if it is down. | |
| 424 | + - Pages: the org-level uptime list (state, 24h uptime, check strip; live) and detail (response-time chart, 24h/7d/30d, changes, checks, heartbeat URL with curl), status page management (`org:write`), and `/status/{org}/{slug}`, public or members-only and live. The public page shows names and states, never targets or reasons. A private page someone can't see looks the same as a missing one. | |
| 425 | + - Tested against a real HTTP server on loopback: down and back each caught on the next check, one alert per change. | |
| 426 | + - Not done: the list page queries per monitor (unbatched). | |
| 414 | 427 | |
| 415 | 428 | ### 9. Logs · medium |
| 416 | 429 | - `log` items arrive from Python as `version: 2` and from Elixir with no version. |
Parents: 061efec