One wide event per request instead of ten log lines
Ten narrow log lines per request repeat the timestamp, the service and the request id ten times and cannot be joined by most backends. One event at the end of the request, with every field on it, is smaller and answers questions the lines could not.
ctx.event.batch_size = items.length;
ctx.event.items_failed = failures.length;
// emitted once, in the middleware's finally"Which tenants had slow requests with more than ten queries on version 4.2" becomes a where clause.
observability
Longer version: the post this came from.