routers_codec 0.2.0

Encoding and Decoding Primitives for Routers
Documentation
[package]
name = "routers_codec"
version = "0.2.0"
edition = "2024"
include = ["docs/**", "build.rs", "proto/**", "src/**"]
description = "Encoding and Decoding Primitives for Routers"
license = "GPL-3.0-or-later"
repository = "https://github.com/routers-org/routers"

[lib]
name = "routers_codec"
path = "./src/lib.rs"
bench = false

[dependencies]
# Sister Crates
routers_network = { workspace = true }
schema = { workspace = true }

# Schema
bytes = { workspace = true }
serde = { workspace = true }
buffa = { workspace = true }

# GeoRust
geo = { workspace = true, features = ["serde"] }
petgraph = { workspace = true, features = ["serde"] }

rayon = { workspace = true }
log = { workspace = true }
postcard = { workspace = true }
rustc-hash = "2.1.1"

# Tracing
tracing = { workspace = true, optional = true }
tracing-subscriber = { workspace = true, optional = true }
strum = { workspace = true }
itertools = { workspace = true }

# Compression
flate2 = { version = "1.1.9", features = ["zlib-rs"] }

# Drop-in for `std::time::Instant`
web-time = "1"

# Misc.
# TODO: Remove dependency.
either = "1.15.0"
regex = "1.11.1"
bitflags = "2.9.1"

[target.'cfg(not(target_arch = "wasm32"))'.dependencies]
mimalloc = { version = "0.1.46", optional = true }

[dev-dependencies]
routers_fixtures = { workspace = true }

test-log = { workspace = true }
criterion = { workspace = true }

# Used to compare performance to ensure no large regression
osmpbf = { version = "0.3.5", features = ["rust-zlib"], default-features = false }

[[bench]]
name = "codec_sweep"
harness = false

[[bench]]
name = "codec_target"
harness = false

[features]
default = ["mimalloc"]

# Alternate Allocator (Applies to #[global_allocator])
mimalloc = ["dep:mimalloc"]

# Tracing (For Debugging & Logging)
tracing = ["dep:tracing", "dep:tracing-subscriber"]

[lints]
workspace = true