You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This submodule is couple with github.com/jackc/pgx/v5 and therefore works for Postgres databases only. This is the reason why this is shipped in a submodule instead of being included in the base module.
This submodule implements the outbox pattern on top of the Bunnify publisher.
How does it work
Whenever you call the Publish function the event is stored in a database table created only if not exists on the creation of the Publisher. This function takes a transaction, which makes your entities + creation of the event atomic.
There is a go routine that every certain duration will try to fetch the outbox events pending for publishing if any. Each one of them will be published in the same way that the bunnify Publisher does. All published events will be marked as published in the database table (or deleted if configured).