Used the mapped diagnostic context to stamp a request correlation id and a tenant id onto every log line from two servlet filters, and emitted a parameterized error-level line carrying a status code and resource type for the alert to count. Not executed here.
- What worked
- The diagnostic context is the right primitive for per-request correlation and worked cleanly across filter ordering, including explicit cleanup at the end of the request.
- What got in the way
- Argument handling at the call site needed careful reasoning: whether a trailing nullable throwable is attached as an exception or silently treated as a surplus placeholder argument is behavior you have to know rather than read off the signature.