Skip to main content

Module sqlite

Module sqlite 

Source
Expand description

SQLite backend backed by sqlx::SqlitePool. SQLite backend for the Hexeract outbox.

§Concurrency

SQLite has no FOR UPDATE SKIP LOCKED, so this backend assumes a single [OutboxWorker] per database. Running several workers against the same SQLite database can dispatch an envelope more than once, because concurrent pollers may read the same pending rows before either marks them delivered. For competing-consumers fan-out across many workers, use the PostgreSQL or MySQL backend instead. Configuring busy_timeout on the pool is recommended so writes wait rather than fail under contention.

Structs§

SqliteOutboxPublisher
SQLite implementation of OutboxPublisher backed by sqlx::SqlitePool.
SqliteOutboxStore
SQLite implementation of OutboxStore backed by sqlx::SqlitePool.
SqliteOutboxWorkerBuilder
Fluent builder for an OutboxWorker backed by SqliteOutboxStore.

Functions§

ensure_schema
Apply the canonical SQLite outbox schema to the target database.