All twenty problems
B4What the client asks

“How will we know when it breaks?”

Errors, latency, resource use. And the slow page nobody can find, because no single query in it is slow.

What actually goes wrong

The honest failure is not a crash. It is a page that takes four seconds because it runs two hundred queries, none of which is slow enough to appear in a slow-query log.

Without a trace that ties a request to the queries it ran, that page is diagnosed by guessing.

What Grit does about it

  • Every request is traced with the queries it ran and what each cost, so the two hundred show up as two hundred.
  • A health endpoint reports each dependency separately and distinguishes “off because nobody configured it” from “configured and broken”.
  • Every request carries an ID, returned in a header and attached to every log line, so a support message becomes one search.

The commands

Already running
grit start
# http://localhost:8080/pulse
What a load balancer should read
curl localhost:8080/health
What the dev servers printed
grit logs --errors

What it does not do

It tells you what is happening in the process. It does not page anybody: alerting is a service you still choose and wire up.

Read next