[go: up one dir, main page]

mongodb 3.4.1

The official MongoDB driver for Rust
Documentation
[package]
description = "The official MongoDB driver for Rust"
keywords = ["mongo", "mongodb", "database", "bson", "nosql"]
categories = ["asynchronous", "database", "web-programming"]
homepage = "https://www.mongodb.com/docs/drivers/rust/"
readme = "README.md"
name = "mongodb"
version = "3.4.1"

authors.workspace = true
license.workspace = true
edition.workspace = true
repository.workspace = true
rust-version.workspace = true

exclude = [
    "etc/**",
    "rustfmt.toml",
    ".evergreen/**",
    ".gitignore",
    "src/test/**",
    "tests/**",
]

[features]
default = ["compat-3-0-0", "rustls-tls", "dns-resolver"]
compat-3-0-0 = ["compat-3-3-0", "bson-2"]
compat-3-3-0 = []
bson-2 = ["dep:bson2", "mongocrypt?/bson-2"]
bson-3 = ["dep:bson3", "mongocrypt?/bson-3"]
sync = []
rustls-tls = ["dep:rustls", "dep:tokio-rustls", "dep:webpki-roots"]
openssl-tls = ["dep:openssl", "dep:openssl-probe", "dep:tokio-openssl"]
dns-resolver = ["dep:hickory-resolver", "dep:hickory-proto"]
cert-key-password = ["dep:pem", "dep:pkcs8"]

# Enable support for MONGODB-AWS authentication.
aws-auth = ["dep:aws-config", "dep:aws-credential-types", "dep:aws-sigv4", "dep:chrono", "dep:http"]

# Enable support for on-demand Azure KMS credentials.
azure-kms = ["dep:reqwest"]

# Enable support for azure OIDC authentication.
azure-oidc = ["dep:reqwest"]

# Enable support for gcp OIDC authentication.
gcp-oidc = ["dep:reqwest"]

# Enable support for on-demand GCP KMS credentials.
gcp-kms = ["dep:reqwest"]

# Enable support for GSSAPI (Kerberos) authentication.
gssapi-auth = ["dep:cross-krb5", "dep:windows-sys", "dns-resolver"]

zstd-compression = ["dep:zstd"]
zlib-compression = ["dep:flate2"]
snappy-compression = ["dep:snap"]

# Enables support for client-side field level encryption and queryable encryption.
in-use-encryption = ["dep:mongocrypt", "dep:rayon", "dep:num_cpus"]
# The in-use encryption API is stable; this is for backwards compatibility.
in-use-encryption-unstable = ["in-use-encryption"]

# Enables support for emitting tracing events.
# The tracing API is unstable and may have backwards-incompatible changes in minor version updates.
# TODO: pending https://github.com/tokio-rs/tracing/issues/2036 stop depending directly on log.
tracing-unstable = ["dep:tracing", "dep:log", "bson3?/serde_json-1"]

# Enables support for text indexes in explicit encryption. This feature is in preview and should be
# used for experimental workloads only. This feature is unstable and its security is not guaranteed
# until released as Generally Available (GA). The GA version of this feature may not be backwards
# compatible with the preview version.
text-indexes-unstable = []

# Enable support for opentelemetry instrumentation
opentelemetry = ["dep:opentelemetry"]

# Capture backtraces in errors.  This can be slow, memory intensive, and very verbose.
error-backtrace = []

[dependencies]
base64 = "0.22"
bitflags = "2"
chrono = { version = "0.4.32", default-features = false, optional = true, features = [
    "now",
    "std",
] }
derive_more = { version = "2", features = ["display", "from"] }
derive-where = "1.2.7"
flate2 = { version = "1.0", optional = true }
futures-io = "0.3.21"
futures-core = "0.3.14"
futures-util = { version = "0.3.14", features = ["io"] }
hex = "0.4.0"
hickory-proto = { version = "0.25", optional = true }
hickory-resolver = { version = "0.25", optional = true }
hmac = "0.12.1"
log = { version = "0.4.17", optional = true }
md-5 = "0.10.1"
mongodb-internal-macros = { path = "../macros", version = "3.4.1" }
num_cpus = { version = "1.13.1", optional = true }
openssl = { version = "0.10.38", optional = true }
openssl-probe = { version = "0.1.5", optional = true }
opentelemetry = { version = "0.31.0", optional = true }
pem = { version = "3.0.4", optional = true }
percent-encoding = "2.0.0"
pkcs8 = { version = "0.10.2", features = ["encryption", "pkcs5"], optional = true }
rand = { version = "0.9", features = ["small_rng"] }
rayon = { version = "1.5.3", optional = true }
rustc_version_runtime = "0.3.0"
serde_with = { version = "3.8.1", default-features = false, features = ["macros"] }
sha1 = "0.10.0"
sha2 = "0.10.2"
snap = { version = "1.0.5", optional = true }
stringprep = "0.1.2"
strsim = "0.11.1"
take_mut = "0.2.2"
thiserror = "2"
tokio-openssl = { version = "0.6.3", optional = true }
tracing = { version = "0.1.36", optional = true }
typed-builder = "0.22.0"
webpki-roots = { version = "1", optional = true }
zstd = { version = "0.11.2", optional = true }
macro_magic = "0.5.1"
rustversion = "1.0.20"
tokio-util = { version = "0.7.0", features = ["compat"] }

[dependencies.aws-config]
version = "1"
optional = true
default-features = false
features = ["default-https-client", "rt-tokio"]


[dependencies.aws-credential-types]
version = "1.2.4"
optional = true
default-features = false

[dependencies.aws-sigv4]
version = "1.3.3"
optional = true
default-features = false
features = ["sign-http"]

[dependencies.http]
version = "1.3"
optional = true
default-features = false

[dependencies.bson2]
version = "2.15.0"
git = "https://github.com/mongodb/bson-rust"
branch = "2.15.x"
package = "bson"
optional = true

[dependencies.bson3]
version = "3.0.0"
git = "https://github.com/mongodb/bson-rust"
branch = "main"
package = "bson"
optional = true
features = ["serde"]

[dependencies.mongocrypt]
version = "0.3.2"
git = "https://github.com/mongodb/libmongocrypt-rust.git"
branch = "main"
default-features = false
optional = true

[dependencies.pbkdf2]
version = "0.12.0"
default-features = false

[dependencies.reqwest]
version = "0.12.12"
optional = true
default-features = false
features = ["json", "rustls-tls"]

[dependencies.rustls]
version = "0.23.20"
optional = true
default-features = false
features = ["logging", "ring", "std", "tls12"]

[dependencies.serde]
version = "1.0.125"
features = ["derive"]

[dependencies.serde_bytes]
version = "0.11.5"

[dependencies.tokio]
version = "1.17.0"
features = ["io-util", "sync", "macros", "net", "process", "rt", "time", "fs"]

[dependencies.tokio-rustls]
version = "0.26"
optional = true
default-features = false
features = ["logging", "ring", "tls12"]

[dependencies.uuid]
version = "1.1.2"
features = ["v4"]

[dev-dependencies]
anyhow = { version = "1.0", features = ["backtrace"] }
approx = "0.5.1"
backtrace = { version = "0.3.68" }
chrono = { version = "0.4.32", default-features = false, features = ["std"] }
function_name = "0.2.1"
futures = "0.3"
hex = "0.4"
home = "0.5"
lambda_runtime = "0.6.0"
opentelemetry_sdk = { version = "0.31.0", features = ["testing"] }
pkcs8 = { version = "0.10.2", features = ["3des", "des-insecure", "sha1-insecure"] }
pretty_assertions = "1.3.0"
serde = { version = ">= 0.0.0", features = ["rc"] }
serde_json = "1.0.64"
semver = "1.0.0"
time = "0.3.9"
tokio = { version = ">= 0.0.0", features = ["fs", "parking_lot"] }
regex = "1.6.0"
reqwest = { version = "0.12.2", features = ["rustls-tls"] }
serde-hex = "0.1.0"
serde_path_to_error = "0.1"

[dev-dependencies.bson3]
git = "https://github.com/mongodb/bson-rust"
branch = "main"
package = "bson"
version = "3.0.0"
features = ["serde", "serde_json-1"]

[package.metadata.docs.rs]
rustdoc-args = ["--cfg", "docsrs"]
all-features = true

[target.'cfg(not(wasi))'.dependencies]
socket2 = "0.6"

# Target-specific dependencies for GSSAPI authentication
[target.'cfg(not(windows))'.dependencies]
cross-krb5 = { version = "0.4.2", optional = true, default-features = false }

[target.'cfg(windows)'.dependencies]
windows-sys = { version = "0.60", optional = true, features = ["Win32_Security_Authentication_Identity", "Win32_Security_Credentials", "Win32_Foundation", "Win32_System", "Win32_System_Rpc"] }

[lints.rust]
unexpected_cfgs = { level = "warn", check-cfg = [
    'cfg(mongodb_internal_tracking_arc)',
] }