An API queues work that several Lambda functions process, each with its own invocation ID; distributed traces are sampled. How should developers reliably link application logs for each business operation?
Show the answer
Correct answerA. Propagate an operation ID and include it in every related log
AWhy this is right: An operation-level correlation ID survives asynchronous boundaries and links all related application log entries.
BWhy not this: Tracing provides execution context but does not replace application logs containing business events and state.
CWhy not this: Each invocation has a different ID, so invocation IDs alone do not link the complete business operation.
DWhy not this: Concurrent operations can share timestamps and functions, making timestamp-based matching unreliable.
A correlation ID propagated through queued messages links logs across separate invocations for the same operation. Lambda invocation IDs identify individual invocations, not the entire business operation.