[package]
name = "xdl-database"
version.workspace = true
edition.workspace = true
authors.workspace = true
license.workspace = true
description = "Database connectivity module for XDL - supports PostgreSQL, MySQL, DuckDB, SQLite, ODBC, Redis, and more"
homepage.workspace = true
repository.workspace = true
documentation.workspace = true
[dependencies]
xdl-core = { version = "0.1.1", path = "../xdl-core" }
thiserror.workspace = true
anyhow.workspace = true
tokio = { workspace = true, features = ["full"] }
async-trait = "0.1"
serde = { workspace = true, features = ["derive"] }
serde_json = "1.0"
sqlx = { version = "0.8", features = ["runtime-tokio-native-tls"], optional = true }
postgres = { version = "0.19", features = ["with-serde_json-1"], optional = true }
tokio-postgres = { version = "0.7", features = ["with-serde_json-1"], optional = true }
mysql_async = { version = "0.34", optional = true }
duckdb = { version = "1.1", features = ["bundled"], optional = true }
rusqlite = { version = "0.31", features = ["bundled"], optional = true }
odbc-api = { version = "8.0", optional = true }
redis = { version = "0.27", features = ["tokio-comp", "connection-manager"], optional = true }
rdkafka = { version = "0.36", features = ["tokio"], optional = true }
deadpool = { version = "0.12", optional = true }
deadpool-postgres = { version = "0.14", optional = true }
url = "2.5"
lazy_static = "1.4"
[features]
default = ["postgres-support", "duckdb-support", "redis-support"]
postgres-support = ["tokio-postgres", "deadpool-postgres"]
mysql-support = ["mysql_async"]
duckdb-support = ["duckdb"]
sqlite-support = ["rusqlite"]
odbc-support = ["odbc-api"]
redis-support = ["redis"]
kafka-support = ["rdkafka"]
all = [
"postgres-support",
"mysql-support",
"duckdb-support",
"sqlite-support",
"odbc-support",
"redis-support",
"kafka-support"
]
[dev-dependencies]
tokio-test = "0.4"