[package]
edition = "2024"
rust-version = "1.93"
name = "thread_aware"
version = "0.7.4"
authors = ["The Oxidizer Project Authors"]
build = false
autolib = false
autobins = false
autoexamples = false
autotests = false
autobenches = false
description = "Facilities to support thread-isolated state."
homepage = "https://github.com/microsoft/oxidizer"
readme = "README.md"
keywords = [
"oxidizer",
"thread",
"aware",
]
categories = ["data-structures"]
license = "MIT"
repository = "https://github.com/microsoft/oxidizer/tree/main/crates/thread_aware"
resolver = "2"
[package.metadata.cargo_check_external_types]
allowed_external_types = [
"thread_aware_macros::ThreadAware",
"bytes::bytes::Bytes",
"bytes::bytes_mut::BytesMut",
"http::error::Error",
"http::header::map::HeaderMap",
"http::header::name::HeaderName",
"http::header::value::HeaderValue",
"http::method::Method",
"http::request::Request",
"http::response::Response",
"http::status::StatusCode",
"http::uri::Uri",
"http::uri::authority::Authority",
"http::uri::path::PathAndQuery",
"http::uri::port::Port",
"http::uri::scheme::Scheme",
"http::uri::InvalidUri",
"http::version::Version",
"jiff::civil::date::Date",
"jiff::civil::datetime::DateTime",
"jiff::civil::iso_week_date::ISOWeekDate",
"jiff::civil::time::Time",
"jiff::signed_duration::SignedDuration",
"jiff::span::Span",
"jiff::timestamp::Timestamp",
"uuid::Uuid",
]
[package.metadata.docs.rs]
all-features = true
[features]
bytes = ["dep:bytes"]
default = ["derive"]
derive = ["dep:thread_aware_macros"]
http = ["dep:http"]
jiff02 = ["dep:jiff"]
threads = ["dep:many_cpus"]
uuid = ["dep:uuid"]
[lib]
name = "thread_aware"
path = "src/lib.rs"
[[test]]
name = "derive_compiles"
path = "tests/derive_compiles.rs"
[[test]]
name = "dyn_trait"
path = "tests/dyn_trait.rs"
[[test]]
name = "transfer_pass"
path = "tests/transfer_pass.rs"
[[bench]]
name = "criterion_third_party"
path = "benches/criterion_third_party.rs"
harness = false
required-features = [
"bytes",
"http",
"jiff02",
"uuid",
]
[[bench]]
name = "gungraun_third_party"
path = "benches/gungraun_third_party/main.rs"
harness = false
required-features = [
"bytes",
"http",
"jiff02",
"uuid",
]
[dependencies.bytes]
version = "1.11.1"
optional = true
default-features = false
[dependencies.http]
version = "1.4.1"
features = ["std"]
optional = true
default-features = false
[dependencies.jiff]
version = "0.2.21"
optional = true
default-features = false
[dependencies.many_cpus]
version = "2.1.0"
optional = true
default-features = false
[dependencies.thread_aware_macros]
version = "0.7.4"
optional = true
default-features = false
[dependencies.uuid]
version = "1.21.0"
optional = true
default-features = false
[dev-dependencies.bytes]
version = "1.11.1"
default-features = false
[dev-dependencies.criterion]
version = "0.8.1"
default-features = false
[dev-dependencies.futures]
version = "0.3.31"
features = ["executor"]
default-features = false
[dev-dependencies.http]
version = "1.4.1"
features = ["std"]
default-features = false
[dev-dependencies.jiff]
version = "0.2.21"
default-features = false
[dev-dependencies.many_cpus]
version = "2.1.0"
features = ["test-util"]
default-features = false
[dev-dependencies.mutants]
version = "0.0.3"
default-features = false
[dev-dependencies.static_assertions]
version = "1.1.0"
default-features = false
[dev-dependencies.uuid]
version = "1.21.0"
default-features = false
[target.'cfg(target_os = "linux")'.dev-dependencies.gungraun]
version = "0.19.0"
features = ["default"]
default-features = false
[lints.clippy]
allow_attributes = "warn"
allow_attributes_without_reason = "warn"
as_pointer_underscore = "warn"
assertions_on_result_states = "warn"
clone_on_ref_ptr = "warn"
deref_by_slicing = "warn"
disallowed_script_idents = "warn"
empty_drop = "warn"
empty_enum_variants_with_brackets = "warn"
empty_structs_with_brackets = "warn"
fn_to_numeric_cast_any = "warn"
if_then_some_else_none = "warn"
map_err_ignore = "warn"
missing_const_for_fn = "allow"
multiple_crate_versions = "allow"
multiple_unsafe_ops_per_block = "warn"
option_if_let_else = "allow"
panic = "warn"
redundant_pub_crate = "allow"
redundant_type_annotations = "warn"
renamed_function_params = "warn"
semicolon_outside_block = "warn"
should_panic_without_expect = "allow"
significant_drop_tightening = "allow"
undocumented_unsafe_blocks = "warn"
unnecessary_safety_comment = "warn"
unnecessary_safety_doc = "warn"
unneeded_field_pattern = "warn"
unused_result_ok = "warn"
unwrap_used = "warn"
wildcard_imports = "allow"
[lints.clippy.cargo]
level = "warn"
priority = -1
[lints.clippy.complexity]
level = "warn"
priority = -1
[lints.clippy.correctness]
level = "warn"
priority = -1
[lints.clippy.nursery]
level = "warn"
priority = -1
[lints.clippy.pedantic]
level = "warn"
priority = -1
[lints.clippy.perf]
level = "warn"
priority = -1
[lints.clippy.style]
level = "warn"
priority = -1
[lints.clippy.suspicious]
level = "warn"
priority = -1
[lints.rust]
ambiguous_negative_literals = "warn"
missing_debug_implementations = "warn"
missing_docs = "warn"
redundant_imports = "warn"
redundant_lifetimes = "warn"
trivial_numeric_casts = "warn"
unreachable_pub = "warn"
unsafe_op_in_unsafe_fn = "warn"
unused_lifetimes = "warn"
[lints.rust.unexpected_cfgs]
level = "warn"
priority = 0
check-cfg = [
"cfg(coverage,coverage_nightly)",
"cfg(loom)",
]
[lints.rustdoc]
missing_crate_level_docs = "warn"
unescaped_backticks = "warn"