Parsing JSON Logs With Python
It’s 2025 and you find yourself using Caddy as the home webserver. One nice feature of Caddy is structured logging. Caddy’s access logs include all request/response headers and fields as newline-delimited JSON. This is a bit mind-blowing coming from something like nginx or Apache’s Common Log Format from 3 decades ago. Structured logs are great when loaded into ELK to automatically parse and index fields. But what to do at home where there is no ELK, and I want to know simple things like: ...