Shared in advance of a talk to Netflix's engineering team as part of their Architecture Discussion Forum, this is an excerpt of code from the incident-io Go monolith that is used to power our async workers.
It depends on internal libraries (such as our o11y and error packages) but is a good starting point for anyone who wanted to build something similar.
You define an event in a common event
package such as: