# 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.88.0"
name = "sea-clickhouse"
version = "0.14.4"
authors = [
    "ClickHouse Contributors",
    "Paul Loyd <pavelko95@gmail.com>",
]
build = false
autolib = false
autobins = false
autoexamples = false
autotests = false
autobenches = false
description = "ClickHouse Client with SeaQL integration"
readme = "README.md"
keywords = [
    "clickhouse",
    "database",
]
license = "MIT OR Apache-2.0"
repository = "https://github.com/SeaQL/clickhouse-rs"

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

[features]
arrow = [
    "sea-orm-arrow",
    "sea-ql",
]
bigdecimal = [
    "sea-query?/with-bigdecimal",
    "sea-orm-arrow?/with-bigdecimal",
]
chrono = [
    "dep:chrono",
    "sea-query?/with-chrono",
    "sea-orm-arrow?/with-chrono",
]
default = ["lz4"]
futures03 = []
inserter = ["dep:quanta"]
lz4 = [
    "dep:lz4_flex",
    "dep:cityhash-rs",
]
native-tls = ["dep:hyper-tls"]
rust_decimal = [
    "sea-query?/with-rust_decimal",
    "sea-orm-arrow?/with-rust_decimal",
]
rustls-tls = [
    "rustls-tls-aws-lc",
    "rustls-tls-webpki-roots",
]
rustls-tls-aws-lc = [
    "dep:rustls",
    "dep:hyper-rustls",
    "hyper-rustls?/aws-lc-rs",
]
rustls-tls-native-roots = [
    "dep:rustls",
    "dep:hyper-rustls",
    "hyper-rustls?/native-tokio",
]
rustls-tls-ring = [
    "dep:rustls",
    "dep:hyper-rustls",
    "hyper-rustls?/ring",
]
rustls-tls-webpki-roots = [
    "dep:rustls",
    "dep:hyper-rustls",
    "hyper-rustls?/webpki-tokio",
]
sea-ql = ["sea-query"]
test-util = ["hyper/server"]
time = [
    "dep:time",
    "sea-query?/with-time",
    "sea-orm-arrow?/with-time",
]
uuid = [
    "dep:uuid",
    "sea-query?/with-uuid",
]

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

[[example]]
name = "arrow_batch"
path = "examples/arrow_batch.rs"
required-features = ["arrow"]

[[example]]
name = "arrow_batch_schema"
path = "examples/arrow_batch_schema.rs"

[[example]]
name = "arrow_insert"
path = "examples/arrow_insert.rs"
required-features = [
    "arrow",
    "rust_decimal",
    "bigdecimal",
]

[[example]]
name = "arrow_sensor_data"
path = "examples/arrow_sensor_data.rs"
required-features = [
    "arrow",
    "rust_decimal",
]

[[example]]
name = "async_insert"
path = "examples/async_insert.rs"

[[example]]
name = "clickhouse_cloud"
path = "examples/clickhouse_cloud.rs"
required-features = ["rustls-tls"]

[[example]]
name = "clickhouse_settings"
path = "examples/clickhouse_settings.rs"

[[example]]
name = "custom_http_client"
path = "examples/custom_http_client.rs"

[[example]]
name = "custom_http_headers"
path = "examples/custom_http_headers.rs"

[[example]]
name = "data_row_insert"
path = "examples/data_row_insert.rs"
required-features = ["sea-ql"]

[[example]]
name = "data_row_schema"
path = "examples/data_row_schema.rs"
required-features = [
    "sea-ql",
    "chrono",
    "rust_decimal",
]

[[example]]
name = "data_rows"
path = "examples/data_rows.rs"
required-features = ["sea-ql"]

[[example]]
name = "data_types_derive_containers"
path = "examples/data_types_derive_containers.rs"

[[example]]
name = "data_types_derive_simple"
path = "examples/data_types_derive_simple.rs"
required-features = [
    "time",
    "uuid",
    "chrono",
]

[[example]]
name = "data_types_new_json"
path = "examples/data_types_new_json.rs"

[[example]]
name = "data_types_variant"
path = "examples/data_types_variant.rs"
required-features = ["time"]

[[example]]
name = "enums"
path = "examples/enums.rs"

[[example]]
name = "inserter"
path = "examples/inserter.rs"
required-features = ["inserter"]

[[example]]
name = "mock"
path = "examples/mock.rs"
required-features = ["test-util"]

[[example]]
name = "query_id"
path = "examples/query_id.rs"

[[example]]
name = "row_batch"
path = "examples/row_batch.rs"
required-features = ["sea-ql"]

[[example]]
name = "server_side_params"
path = "examples/server_side_params.rs"

[[example]]
name = "session_id"
path = "examples/session_id.rs"

[[example]]
name = "stream_arbitrary_format_rows"
path = "examples/stream_arbitrary_format_rows.rs"

[[example]]
name = "stream_into_file"
path = "examples/stream_into_file.rs"

[[example]]
name = "time_types_example"
path = "examples/time_types_example.rs"
required-features = [
    "time",
    "chrono",
]

[[example]]
name = "usage"
path = "examples/usage.rs"

[[test]]
name = "it"
path = "tests/it/main.rs"

[[test]]
name = "ui"
path = "tests/ui.rs"

[[bench]]
name = "common"
path = "benches/common.rs"

[[bench]]
name = "common_select"
path = "benches/common_select.rs"

[[bench]]
name = "mocked_insert"
path = "benches/mocked_insert.rs"
harness = false

[[bench]]
name = "mocked_select"
path = "benches/mocked_select.rs"
harness = false

[[bench]]
name = "select_market_data"
path = "benches/select_market_data.rs"
harness = false

[[bench]]
name = "select_numbers"
path = "benches/select_numbers.rs"
harness = false

[[bench]]
name = "select_nyc_taxi_data"
path = "benches/select_nyc_taxi_data.rs"
harness = false
required-features = ["time"]

[dependencies.bnum]
version = "0.13.0"

[dependencies.bstr]
version = "1.11.0"
default-features = false

[dependencies.bytes]
version = "1.5.0"
features = ["serde"]

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

[dependencies.cityhash-rs]
version = "=1.0.1"
optional = true

[dependencies.clickhouse-macros]
version = "0.3.0"

[dependencies.clickhouse-types]
version = "0.1.1"

[dependencies.futures-channel]
version = "0.3.30"
features = ["sink"]

[dependencies.futures-util]
version = "0.3.5"
features = [
    "sink",
    "io",
]
default-features = false

[dependencies.http-body-util]
version = "0.1.2"

[dependencies.hyper]
version = "1.4"

[dependencies.hyper-rustls]
version = "0.27.3"
features = [
    "http1",
    "tls12",
]
optional = true
default-features = false

[dependencies.hyper-tls]
version = "0.6.0"
optional = true

[dependencies.hyper-util]
version = "0.1.6"
features = [
    "client-legacy",
    "http1",
]

[dependencies.lz4_flex]
version = "0.11.3"
features = ["std"]
optional = true
default-features = false

[dependencies.polonius-the-crab]
version = "0.5.0"

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

[dependencies.rustls]
version = "0.23"
optional = true
default-features = false

[dependencies.sea-orm-arrow]
version = "2.0.0-rc"
features = ["prettyprint"]
optional = true

[dependencies.sea-query]
version = "1.0.0-rc"
features = ["with-json"]
optional = true
default-features = false

[dependencies.serde]
version = "1.0.106"

[dependencies.thiserror]
version = "2.0"

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

[dependencies.tokio]
version = "1.0.1"
features = [
    "rt",
    "macros",
]

[dependencies.url]
version = "2.1.1"

[dependencies.uuid]
version = "1"
optional = true

[dev-dependencies.clickhouse-macros]
version = "0.3.0"

[dev-dependencies.criterion]
version = "0.6"

[dev-dependencies.fixnum]
version = "0.9.2"
features = [
    "serde",
    "i32",
    "i64",
    "i128",
]

[dev-dependencies.fxhash]
version = "0.2.1"

[dev-dependencies.hyper]
version = "1.1"
features = ["server"]

[dev-dependencies.indexmap]
version = "2.10.0"
features = ["serde"]

[dev-dependencies.linked-hash-map]
version = "0.5.6"
features = ["serde_impl"]

[dev-dependencies.rand]
version = "0.9"
features = ["small_rng"]

[dev-dependencies.serde]
version = "1.0.106"
features = ["derive"]

[dev-dependencies.serde_bytes]
version = "0.11.4"

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

[dev-dependencies.serde_repr]
version = "0.1.7"

[dev-dependencies.time]
version = "0.3.17"
features = [
    "macros",
    "rand",
    "parsing",
]

[dev-dependencies.tokio]
version = "1.0.1"
features = [
    "full",
    "test-util",
    "io-util",
]

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

[dev-dependencies.uuid]
version = "1"
features = [
    "v4",
    "serde",
]

[lints.clippy]
undocumented_unsafe_blocks = "warn"

[lints.rust]
unexpected_cfgs = "allow"
unreachable_pub = "warn"

[lints.rust.rust_2018_idioms]
level = "warn"
priority = -1

[profile.release]
debug = 2
