#![forbid(unsafe_code)]
#![deny(missing_docs)]
pub mod client;
pub mod error;
pub mod from_row;
pub mod health;
pub mod metrics;
pub mod raw;
pub mod row;
pub mod transaction;
pub mod value;
#[cfg(feature = "pg")]
pub mod pg;
#[cfg(feature = "migrate")]
pub mod migrate;
#[cfg(feature = "proptest")]
pub mod testing;
pub use client::{
SqlClient, SqlClientEnv, SqlClientService, TestSqlClient, execute, provide_sql_client, query,
sql_client_env, sql_client_layer,
};
pub use error::{SQLSTATE_UNIQUE_VIOLATION, SqlError};
pub use from_row::{FromRow, query_as, query_one_as, query_opt_as};
pub use id_effect_proc_macro::FromRow;
pub use raw::{RawSql, RawSqlCapability, RawSqlEnv, Sql, execute_raw, query_raw};
pub use row::{ColumnIndex, SqlColumn, SqlRow};
pub use value::{FromSqlValue, Json, SqlType, SqlValue, ToSqlValue, ValueError};
pub use transaction::{
SqlTransaction, SqlTransactionEnv, SqlTransactionService, transaction, transaction_layer,
with_transaction,
};
pub use {jiff, rust_decimal, serde_json, uuid};
pub use transaction::with_transaction as transaction_scope;
#[cfg(doctest)]
#[doc = include_str!("../README.md")]
struct ReadmeDoctests;
pub mod stream;
pub use stream::{query_stream, query_stream_as};
pub use transaction::{
Isolation, SQLSTATE_DEADLOCK_DETECTED, SQLSTATE_SERIALIZATION_FAILURE, TransactionOptions,
is_serialization_failure, retry_serialization_failures, savepoint, transaction_with,
with_transaction_options,
};
#[cfg(feature = "query")]
#[path = "query/mod.rs"]
pub mod query_builder;
#[cfg(feature = "query")]
pub use query_builder::{
BuildSql, Dialect, execute_query, fetch_all_as, fetch_one_as, fetch_optional_as,
};
#[cfg(feature = "sqlite")]
pub mod sqlite;
pub mod routing;
pub use routing::{ReadRouting, RoutingSqlClient};
pub mod tenant_routing;
pub use tenant_routing::{
DEFAULT_MAX_TENANT_POOLS, TenantClientFactory, TenantConnector, TenantRouter, TenantSqlClient,
tenant_database, tenant_database_from,
};
#[cfg(feature = "audit")]
pub mod audit;
#[cfg(feature = "repository")]
pub mod repository;
#[cfg(feature = "repository")]
pub use id_effect_proc_macro::Entity;
#[cfg(feature = "repository")]
pub use repository::{BoundRepository, CurrentTenant, Entity, Page, Repository, SqlExecutor};
#[cfg(feature = "repository")]
pub use repository::{EagerRepository, FieldMeta, Loaded, Relation, RelationMeta};
#[cfg(feature = "repository")]
pub use repository::{Keyset, PageCursor, Paged, SortOrder};
#[cfg(feature = "mysql")]
pub mod mysql;