[package]
name = "memberlist-types"
version = "0.3.1"
edition.workspace = true
license.workspace = true
repository.workspace = true
homepage.workspace = true
readme.workspace = true
rust-version.workspace = true
keywords.workspace = true
categories.workspace = true
description = "Types used in the memberlist crate."

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

[features]
default = []
metrics = ["dep:metrics"]
encryption = ["async-lock", "indexmap"]

serde = [
  "dep:serde",
  "smol_str/serde",
  "smallvec-wrapper/serde",
  "base64",
  "ipnet/serde",
  "bytes/serde",
  "nodecraft/serde",
  "indexmap?/serde"
]
rkyv = ["dep:rkyv", "smallvec-wrapper/rkyv", "nodecraft/rkyv"]

[dependencies]
bytes.workspace = true
byteorder.workspace = true
derive_more.workspace = true
futures.workspace = true
ipnet = "2"
nodecraft.workspace = true
paste.workspace = true
transformable = { workspace = true, features = ["bytes1", "smol_str03"] }
thiserror.workspace = true
smol_str.workspace = true
smallvec-wrapper.workspace = true
viewit.workspace = true

indexmap = { workspace = true, optional = true }
async-lock = { workspace = true, optional = true }

metrics = { workspace = true, optional = true }

serde = { workspace = true, optional = true }
base64 = { version = "0.22", optional = true }

rkyv = { workspace = true, optional = true }

[dev-dependencies]
rand = "0.9"
tokio = { version = "1", features = ["full"] }
