A Go outbox library that runs inside your own DB transaction (opens in new tab)
TL;DR — tickr is a Go library. It stores messages in one Postgres table. You add messages inside your own database transaction. A worker pool in the same Go process reads them back using SELECT … FOR UPDATE SKIP LOCKED and runs your handler. It ships with Prometheus metrics, OpenTelemetry tracing, and a Grafana dashboard. No broker. No second datastore. The problem: two writes, one of them will fail Most services I've worked on end up with code like this: func CreateOrder(ctx context.Context,...
Read the original article