#[cfg(not(any(feature = "db-postgres", feature = "db-mysql")))]
compile_error!(
"rusty-gasket-db requires at least one backend feature. Enable `postgres` or `mysql` \
(or both) in your Cargo.toml — for example:\n\n \
[dependencies]\n \
rusty-gasket-db = { version = \"0.1\", features = [\"postgres\"] }\n\n\
Building with neither feature produces a runtime pool that registers no SQLx drivers."
);
mod config;
mod extractor;
mod plugin;
mod transaction;
pub use config::{ConfigError, DatabaseBackend, DatabaseConfig, ResolvedBackend};
pub use extractor::{DbTx, DbTxNotAvailable};
pub use plugin::DatabasePlugin;
pub use rusty_gasket::BoxError;
pub use transaction::{
RequestTransaction, TransactionMiddlewareState, begin_tracked_transaction,
transaction_middleware,
};
pub use sqlx::AnyPool;
pub mod prelude {
pub use rusty_gasket::db::{
BoxError, DatabaseConfig, DatabasePlugin, DbTx, DbTxNotAvailable, RequestTransaction,
};
}