Logging Strategy
Decides what to log from the questions you will need to answer at 3am, rather than logging everything and finding nothing.
Free — no card needed
Create a free account
to open Logging Strategy — and the other 364 prompts across 21 categories.
Already have an account?
Running it, start to finish
- Write down the questions an incident will need answered.
- Thread a request id through everything, including outbound calls.
- Check the design against a past incident before adopting it.
What you get back
The output this produces, every time.
- Designs backwards from the questions an incident will ask, rather than forwards from what seems interesting.
- Logs the inputs to a decision, not just its outcome, which is what makes a rejection diagnosable.
- Tests the design against your actual incident history, which is the only real check.
Getting better results
Where this usually goes wrong, and how to avoid it.
- Log events with fields, not sentences. A concatenated message cannot be filtered or aggregated, which is the whole difference between logs and useful logs.
- Log the start of long operations. Logging only completion makes a hung operation invisible, which is precisely when you most need to see it.
- Reserve error for things people act on. An error level nobody responds to trains everyone to ignore it, and then the real one is missed too.
More Coding prompts
All Coding →- Coding
Refactor With a Safety Net
Plans a refactor as a sequence of individually safe, individually shippable steps, with the characterisation tests that make each one verifiable.
ClaudeChatGPT000Open → - Coding
Review for the Bug, Not the Style
A code review that hunts correctness failures and states the exact input that breaks each one, instead of listing naming preferences.
ClaudeChatGPTGemini000Open → - Coding
Database Migration Plan
Plans a schema change that ships without downtime, in steps that are each independently safe and reversible.
ClaudeChatGPT000Open →
Written for The AI University. Every prompt in this library is original work — authored, tested and revised here, not collected from elsewhere. 365 of them, free with an account.
