New: Cookbooks and AI ExplanationsStep-by-Step recipes to solve problems connected to Roadmaps and Cheat Sheets. Need more details? Use AI buttons for structured and simple explanations with concrete examples throughout the whole platform.Take a look
A webhook consumer of mine crashed right after writing to the database but before acking the message, and it got redelivered and processed twice.
What you'll have at the end
A consumer that can process the exact same message five times in a row and only ever charge the customer once
You need
A queue consumer that already acknowledges manually, only once its handler finishes, and that writes a record to a database for every event it processes.
Not covered
Deciding how long a processed event's row should live before it's safe to delete comes later, once the table is already carrying real traffic.
Leans on
Stop a crash from losing a job nobody acknowledged
if events are still vanishing outright rather than being processed twice, that's the more basic failure to close first, before duplicate handling matters at all.
Prove a message reached the broker with a publisher confirm
covers the publish side of the same worry, confirming the broker actually has the event before your producer moves on, a different failure than a landed event getting processed twice.
Checked 19 Aug 2026
Part of the Message Queues cookbook