footing 0.4.2

Feature-gated foundations for Rust backend services
Documentation
//! SQLx PostgreSQL helpers with explicit configuration, diagnostics, and runtime boundaries.

#[cfg(feature = "postgres-admin")]
#[cfg_attr(docsrs, doc(cfg(feature = "postgres-admin")))]
/// Explicitly gated destructive PostgreSQL administration operations.
pub mod admin;
mod config;
mod diagnostics;
mod identity;
mod runtime;

pub use config::{
    DEFAULT_POSTGRES_ADVISORY_LOCK_TIMEOUT, DEFAULT_POSTGRES_ENSURE_DATABASE_TIMEOUT,
    DEFAULT_POSTGRES_MIGRATION_TIMEOUT, PostgresBootstrapConfig, PostgresBootstrapSettings,
    PostgresPoolConfig, PostgresPoolSettings, PostgresStartupRetryConfig,
    PostgresStartupRetrySettings,
};
pub use diagnostics::{
    PostgresBootstrapError, PostgresDiagnostic, PostgresDiagnosticKind, PostgresOperation,
    PostgresPoolError, diagnose_migration_error, diagnose_migration_lock_timeout,
    diagnose_operation_timeout, diagnose_pool_error, diagnose_sqlx_error,
};
pub use identity::{
    advisory_lock_key, database_name, redact_database_url, schema_maintenance_advisory_lock_key,
};
pub use runtime::{
    PostgresHealth, PostgresHealthStatus, PostgresMigrationRunError, PostgresTransaction,
    acquire_advisory_transaction_lock, acquire_shared_advisory_transaction_lock,
    bootstrap_database, check_pool_health, connect_lazy_pool, connect_pool,
    connect_pool_with_retry, ensure_database_exists, ensure_database_exists_with_retry, ping_pool,
    pool_options, run_migrations, run_migrations_with_timeouts,
    try_acquire_advisory_transaction_lock,
};

#[cfg(test)]
use runtime::POSTGRES_HEALTH_ERROR;

#[cfg(test)]
mod tests;