r/aws • u/goyalaman_ • 1h ago
discussion Trace Emails Across SES Boundries
I have a email service which uses aws ses to send out emails. Additionally there is a service which listens to bounces (via sns). Currently request journey is traceable till the email-service via trace-id but the bounces received in bounce receivers can't be traced with original request because trace-id is not passed through ses.
Currently, we use aws ses's message-id to relate trace-id and and message-id across the ses boundary.
I am wondering if there is way to propagate trace-id from email-service across aws ses to bounce-receiving service? Right now, the potential solution I am thinking is passing in a custom header (like x-trace-id) to the email and then using that custom header via bounce event in bounce-receriver service?
I am open to suggestions (if this is not the right place to discuss this, lmk I'll remove this)
