How should I carry a correlation ID from the HTTP request all the way into queued jobs?
Generate the ID as a W3C `traceparent`, carry it in an SQS message attribute rather than the body, and inject it with the OTel propagator on both sides.
Tag
Metrics, logs and traces: reading what a system does from the outside.
6 answered questions carry this tag.
Generate the ID as a W3C `traceparent`, carry it in an SQS message attribute rather than the body, and inject it with the OTel propagator on both sides.
Log at ERROR when the line would wake someone at 3am and at WARN when it would not, log a failure once at its boundary, and alert on the ERROR rate.
Hold the new version at a canary weight and check 5xx and latency against a threshold; on breach, roll back to the last stable release and alert the team.
Collapse repeated errors into one counted line, back off retries, cap logrotate by size and count, and give `/var/log` a volume off the root disk.
Standardize on W3C Trace Context, leave propagation to the OTel SDK, and put traceparent in the queue message header, since that is where the chain snaps.
Turn on Fluent Bit's filesystem buffer first; move to Kafka once 40k/s is permanent, and keep a Redis list only for logs you can afford to lose.