Skip to main content

Crate bsql_core

Crate bsql_core 

Source
Expand description

Runtime support for bsql.

This crate provides the types that bsql::query! generated code depends on: error types, connection pool, and the executor trait.

You should not depend on this crate directly — use [bsql] instead.

Re-exports§

pub use error::BsqlError;
pub use error::BsqlResult;
pub use executor::OwnedResult;
pub use executor::QueryTarget;
pub use listener::Listener;
pub use listener::Notification;
pub use pool::Pool;
pub use pool::PoolBuilder;
pub use pool::PoolConnection;
pub use pool::PoolStatus;
pub use stream::QueryStream;
pub use transaction::IsolationLevel;
pub use transaction::Transaction;

Modules§

driver
Re-export bsql_driver_postgres types used by generated code. Users do not need to depend on bsql-driver directly.
error
Error types for bsql.
executor
Query dispatch via QueryTarget — the runtime contract between generated code and the pool/connection/transaction.
listener
LISTEN/NOTIFY support via a dedicated PostgreSQL connection.
pool
Connection pool — thin wrapper over bsql_driver_postgres::Pool.
singleflight
Singleflight request coalescing for query deduplication.
stream
True PG-level streaming query results.
test_support
Test infrastructure for #[bsql::test].
transaction
Database transactions with commit/rollback.
types
PostgreSQL OID to Rust type mapping.
util
Shared utility functions used across bsql-core modules.