canton-core 0.2.2

Core types for the Canton Rust SDK: error model, telemetry, and the shared connection kernel (config, auth, TLS, retry).
Documentation
# 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"
name = "canton-core"
version = "0.2.2"
authors = ["NODEJUMPER <dmitryk@nodejumper.io>"]
build = false
include = [
    "src/**/*",
    "README.md",
    "LICENSE",
]
autolib = false
autobins = false
autoexamples = false
autotests = false
autobenches = false
description = "Core types for the Canton Rust SDK: error model, telemetry, and the shared connection kernel (config, auth, TLS, retry)."
homepage = "https://nodejumper.io/"
readme = "README.md"
keywords = [
    "canton",
    "grpc",
    "ledger",
    "blockchain",
    "daml",
]
categories = [
    "api-bindings",
    "asynchronous",
    "network-programming",
]
license = "Apache-2.0"
repository = "https://github.com/nodejumper-org/canton-rust-sdk"
resolver = "2"

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

[features]
otel = [
    "dep:opentelemetry",
    "dep:opentelemetry_sdk",
    "dep:opentelemetry-otlp",
    "dep:tracing-opentelemetry",
    "dep:http",
]

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

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

[dependencies.futures-core]
version = "0.3"

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

[dependencies.metrics]
version = "0.24"

[dependencies.opentelemetry]
version = "0.27"
optional = true

[dependencies.opentelemetry-otlp]
version = "0.27"
features = [
    "grpc-tonic",
    "metrics",
]
optional = true

[dependencies.opentelemetry_sdk]
version = "0.27"
features = [
    "rt-tokio",
    "metrics",
]
optional = true

[dependencies.serde_json]
version = "1"

[dependencies.thiserror]
version = "2"

[dependencies.tokio]
version = "1"
features = ["time"]
default-features = false

[dependencies.tokio-stream]
version = "0.1"

[dependencies.tonic]
version = "0.14"
features = [
    "transport",
    "tls-ring",
    "tls-native-roots",
]
default-features = false

[dependencies.tonic-types]
version = "0.14"

[dependencies.tracing]
version = "0.1"

[dependencies.tracing-opentelemetry]
version = "0.28"
optional = true

[dev-dependencies.metrics-util]
version = "0.19"

[dev-dependencies.opentelemetry]
version = "0.27"

[dev-dependencies.opentelemetry-proto]
version = "0.27"
features = [
    "gen-tonic",
    "trace",
    "metrics",
]

[dev-dependencies.opentelemetry_sdk]
version = "0.27"
features = ["rt-tokio"]

[dev-dependencies.otlp-tonic]
version = "0.12"
features = [
    "transport",
    "codegen",
]
package = "tonic"

[dev-dependencies.tokio]
version = "1"
features = [
    "rt",
    "rt-multi-thread",
    "macros",
    "test-util",
]
default-features = false

[dev-dependencies.tokio-stream]
version = "0.1"
features = ["net"]

[dev-dependencies.tracing-opentelemetry]
version = "0.28"

[dev-dependencies.tracing-subscriber]
version = "0.3"

[lints.clippy]
doc_markdown = "allow"
expect_used = "warn"
missing_errors_doc = "allow"
module_name_repetitions = "allow"
unwrap_used = "warn"

[lints.clippy.pedantic]
level = "warn"
priority = -1

[lints.rust]
missing_debug_implementations = "warn"
missing_docs = "warn"
unreachable_pub = "warn"
unsafe_code = "forbid"

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