Skip to main content

Crate boson_backend_sql_common

Crate boson_backend_sql_common 

Source
Expand description

Shared SQL QueueBackend for PostgreSQL and SQLite.

Reference implementation for Developing the backend; integrators typically use boson_backend_sqlite::SqliteQueueBackend or boson_backend_postgres::PostgresQueueBackend.

§Entry points

§Example (integrator wiring)

use boson_backend_sql_common::SqlQueueBackend;

let backend = SqlQueueBackend::connect_sqlite("sqlite://:memory:").await?;

Macros§

delegate_queue_backend
Delegate every QueueBackend method to $inner.
sql_execute
sql_fetch_all
sql_fetch_all_map
sql_fetch_one
sql_fetch_one_map
sql_fetch_optional
sql_fetch_optional_map

Structs§

EnqueueRateLimiter
Tracks recent enqueue timestamps per task name (1-second sliding window).
SqlQueueBackend
SQL-backed queue backend (PostgreSQL or SQLite).

Enums§

SqlDialect
SQL dialect for query variants.
SqlPool
Connection pool for a SQL backend.