~/blog/hoster-0-3-0

hoster 0.3.0

· 3 min read · LHelge

0.3.0 adds an event log, so the admin UI can tell you what happened and when, and fixes the latency figures, which long-lived connections made look far worse than they were.

An event log

hoster now records what it does and what happens to your services, and keeps it for 30 days:

  • Deploys: started, succeeded, failed and rolled back, with where the deploy came from (the UI, a webhook or the registry poller) and the commit when it is known.
  • Containers: a restart with its exit code, a service entering or leaving a crash loop, and a health change of a live service.
  • Certificates: issued, renewed and failed (with the reason and the next retry), and a DNS mismatch.
  • Operator and system: a stack applied or removed, a secret set or deleted (its name, never its value), hoster started, updated or rolled back. Actions taken in the admin UI name the GitHub account that took them.

There are three places to read it:

  • A Recent events card on the dashboard, with new events appearing as they happen.
  • The same card on each stack’s overview, with only that stack’s events.
  • An Events page with the whole log, filterable by kind, severity and stack.

The log starts with this release: nothing from before the update is in it.

Latency means time to the response header

The p50 and p95 figures used to count a request up to the end of its response. A server-sent event stream, a WebSocket or a long download therefore counted as a request as slow as it was long-lived, and on a quiet host a few of them were enough to push p95 to tens of seconds. The admin UI’s own live pages were the usual cause.

The figures now count the time until your service’s response header arrives, which is how long the client waited for an answer. The proxy’s access log still reports the whole duration in duration_ms.

The dashboard’s request, 5xx rate and latency tiles also no longer count the admin UI’s own requests. They are about what hoster hosts. The note under the stacks table still shows them.

Updating

hoster update

Or use Update on the System page. Nothing changed in hoster.toml or in the stack file format. The update adds a table to hoster’s database; rolling back to 0.2 removes it again, and the event history with it.