Orientation: what "observable" actually means
Artifact: The two-minute promise and the five tools that earn it
1. The promise
You'll know what this chapter is for. By the end of Ch 25 you'll answer "what broke, where, and why" on your live app in under two minutes. Right now you can't. By the assignment, you can.
2. The mental model
Observability is how well you can ask new questions about a running system from outside it, without redeploying. It's the dashboard on a car. You don't open the bonnet every time the engine stutters. You glance at the dials. The dials only work because somebody wired sensors to the engine first. This chapter is the wiring.
(DIAGRAM: the car-dashboard analogy — annotated SVG — left panel: car with sensors → dashboard dials → driver; right panel: app with instrumentation → dashboards → developer)
The chapter has two halves. The first half (units 1 to 9) wires observability: logs, metrics, traces, errors. The second half (units 10 to 16) is the security baseline a junior developer is expected to hold. The assignment combines both into one drill.
The five tools you'll have set up by the end:
- Pino — a fast JSON logger for Node.js. It replaces
console.log. - Better Stack — a hosted log aggregator. It receives logs from every service and stores them in one searchable place.
- OpenTelemetry — the vendor-neutral standard for traces and metrics.
- Sentry — error tracking with stack traces, source maps, and release tagging.
- Dependabot — GitHub's bot that opens pull requests when your dependencies have updates.
3. You do it, with me
Open the deployed app from Ch 24 in your browser. It should still be live at its production URL.
(SCREENSHOT: the deployed app from Ch 24 — homepage in the browser — full window — URL bar visible to show this is production)
Open the GitHub repo for the app in a new tab. Click the Actions tab. The CI from Ch 24 should be green.
(SCREENSHOT: the GitHub repo for the app — full window — Actions tab visible to show CI from Ch 24)
Open a third tab to betterstack.com. This is the log aggregator you'll use in unit 25.4. Don't sign up yet — that comes later.
(SCREENSHOT: Better Stack landing page at betterstack.com — full window — the Logs product highlighted)
A short note on cost. Free tiers cover learning. Real production traffic will hit limits. Glance at the Better Stack pricing page so you know what a real bill looks like later.
4. What you should be seeing
- Your deployed app is live at its production URL.
- Your GitHub Actions tab shows a green CI run from Ch 24.
- Three browser tabs are open: your app, your repo, and Better Stack.
If any of those isn't true, go back to Ch 24 and finish it. This chapter assumes a deployed app.
5. Common stumbles
- You skip ahead to Sentry because "errors are what matters." Errors are one signal. Without logs and metrics, you can't tell whether an error is a blip or an outage.
- You worry this chapter is overkill for a small app. The wiring is the same at any scale. The point is the practice, not the traffic.
- You try to set up your own Prometheus, Grafana, and Loki. That's a real-job decision. This chapter uses hosted services because they're free at your traffic level and they remove a class of "my logging is also broken" problems.