# THIS FILE IS AUTOMATICALLY GENERATED BY CARGO
#
# When uploading crates to the registry Cargo will automatically
# "normalize" Cargo.toml files for maximal compatibility
# with all versions of Cargo and also rewrite `path` dependencies
# to registry (e.g., crates.io) dependencies.
#
# If you are reading this file be aware that the original Cargo.toml
# will likely look very different (and much more reasonable).
# See Cargo.toml.orig for the original contents.

[package]
edition = "2024"
rust-version = "1.89"
name = "pjson-rs"
version = "0.6.1"
authors = ["Andrei G. <k05h31@gmail.com>"]
build = "build.rs"
exclude = [
    "/target",
    "/benches",
    "/tests",
    "examples/*",
]
publish = true
autolib = false
autobins = false
autoexamples = false
autotests = false
autobenches = false
description = "Priority JSON Streaming Protocol - high-performance priority-based JSON streaming (requires nightly Rust)"
readme = "README.md"
keywords = [
    "json",
    "streaming",
    "simd",
    "performance",
    "protocol",
]
categories = [
    "encoding",
    "network-programming",
    "parser-implementations",
]
license = "MIT OR Apache-2.0"
repository = "https://github.com/bug-ops/pjs"

[package.metadata.cargo-udeps.ignore]
normal = [
    "axum",
    "tower",
    "tower-http",
    "hyper",
    "futures",
    "sha2",
]

[package.metadata.cargo-machete]
ignored = ["mimalloc"]

[package.metadata.release.publishers.crates-io]
trusted-publishing = true
issuer = "https://token.actions.githubusercontent.com"
repository = "bug-ops/pjs"
workflow = "release.yml"

[features]
compression = [
    "dep:brotli",
    "dep:flate2",
    "dep:zstd",
]
default = [
    "simd-auto",
    "schema-validation",
    "compression",
    "http-server",
    "http-client",
    "websocket-server",
    "websocket-client",
]
http-auth-jwt = [
    "http-server",
    "dep:jsonwebtoken",
]
http-client = ["dep:reqwest"]
http-server = [
    "dep:async-stream",
    "dep:axum",
    "dep:tower",
    "dep:tower-http",
    "dep:futures",
    "dep:subtle",
    "dep:hmac",
    "dep:sha2",
    "dep:getrandom",
]
metrics = [
    "http-server",
    "dep:metrics",
    "dep:metrics-exporter-prometheus",
]
mimalloc = ["dep:mimalloc"]
partial-parse = ["dep:jiter"]
schema-validation = ["dep:regex"]
simd-auto = []
simd-avx2 = []
simd-avx512 = ["sonic-rs/avx512"]
simd-neon = []
simd-sse42 = []
websocket-client = [
    "dep:tokio-tungstenite",
    "dep:url",
]
websocket-server = ["http-server"]

[lib]
name = "pjson_rs"
path = "src/lib.rs"

[dependencies.async-stream]
version = "0.3"
optional = true

[dependencies.axum]
version = "0.8"
features = ["ws"]
optional = true

[dependencies.bitflags]
version = "2.13"

[dependencies.brotli]
version = "8"
features = ["std"]
optional = true
default-features = false

[dependencies.bytes]
version = "1.11"

[dependencies.chrono]
version = "0.4"
features = ["serde"]

[dependencies.crossbeam]
version = "0.8"

[dependencies.dashmap]
version = "6.2"

[dependencies.flate2]
version = "1.1"
features = ["rust_backend"]
optional = true
default-features = false

[dependencies.futures]
version = "0.3"
optional = true

[dependencies.getrandom]
version = "0.3"
optional = true

[dependencies.hmac]
version = "0.12"
optional = true

[dependencies.jiter]
version = "0.14"
optional = true

[dependencies.jsonwebtoken]
version = "10.4"
features = ["use_pem"]
optional = true
default-features = false

[dependencies.maplit]
version = "1.0"

[dependencies.metrics]
version = "0.24"
optional = true

[dependencies.metrics-exporter-prometheus]
version = "0.18"
optional = true

[dependencies.mimalloc]
version = "0.1"
optional = true

[dependencies.once_cell]
version = "1.21"

[dependencies.parking_lot]
version = "0.12"

[dependencies.paste]
version = "1.0"

[dependencies.pjson-rs-domain]
version = "0.6.1"

[dependencies.rayon]
version = "1.12"

[dependencies.regex]
version = "1.12"
optional = true

[dependencies.reqwest]
version = "0.13"
features = ["json"]
optional = true

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

[dependencies.serde_json]
version = "1.0"

[dependencies.sha2]
version = "0.10"
optional = true

[dependencies.smallvec]
version = "1.15"
features = [
    "serde",
    "union",
    "const_generics",
]

[dependencies.sonic-rs]
version = "0.5"

[dependencies.subtle]
version = "2.6"
optional = true

[dependencies.thiserror]
version = "2.0"

[dependencies.tokio]
version = "1.52"
features = [
    "rt-multi-thread",
    "sync",
    "time",
    "macros",
    "net",
    "parking_lot",
]

[dependencies.tokio-tungstenite]
version = "0.29"
optional = true

[dependencies.tower]
version = "0.5"
optional = true

[dependencies.tower-http]
version = "0.6"
features = [
    "cors",
    "trace",
]
optional = true

[dependencies.tracing]
version = "0.1"

[dependencies.typed-arena]
version = "2.0"

[dependencies.url]
version = "2.5"
optional = true

[dependencies.uuid]
version = "1.23"
features = [
    "v4",
    "serde",
]

[dependencies.zstd]
version = "0.13"
features = ["zdict_builder"]
optional = true
default-features = false

[dev-dependencies.serde_json]
version = "1.0"

[dev-dependencies.tokio]
version = "1.52"
features = ["test-util"]

[dev-dependencies.tokio-test]
version = "0.4"
