[package] name = "xtra" version = "0.6.0" description = "A tiny actor framework" authors = ["Restioson "] edition = "2021" license = "MPL-2.0" repository = "https://github.com/Restioson/xtra" documentation = "https://docs.rs/xtra" readme = "../README.md" keywords = ["async", "actor", "futures", "xtra", "async-await"] categories = ["asynchronous", "concurrency"] rust-version = "1.75.0" [dependencies] catty = "0.1.5" futures-core = "0.3.21" # alloc is the only default feature and we need it. futures-sink = { version = "0.3.21", default-features = false, optional = true } futures-util = { version = "0.3.21", default-features = false } pin-project-lite = "0.2.9" event-listener = "2.4.0" spin = { version = "0.9.3", default-features = false, features = ["spin_mutex"] } async-std = { version = "1.0", features = ["unstable"], optional = true } smol = { version = "1.1", optional = true } tokio = { version = "1.0", features = ["rt", "time"], optional = true } wasm-bindgen = { version = "0.2", optional = true, default-features = false } wasm-bindgen-futures = { version = "0.4", optional = true, default-features = false } # Feature `instrumentation` tracing = { version = "0.1.35", optional = true, default-features = false } macros = { package = "xtra-macros", version = "0.6.0", optional = true } [dev-dependencies] rand = "0.8" smol = "1.1" smol-potat = "1.1" smol-timeout = "0.6" waker-fn = "1.1" criterion = { version = "0.3", features = ["async_tokio"] } tokio = { version = "1.21", features = ["full"] } async-std = { version = "1.0", features = ["attributes"] } tracing = { version = "0.1.35", features = ["std"] } tracing-subscriber = { version = "0.3.17", features = ["env-filter"] } futures-util = "0.3.21" [features] default = [] macros = ["dep:macros"] instrumentation = ["dep:tracing"] async_std = ["dep:async-std"] smol = ["dep:smol"] tokio = ["dep:tokio"] wasm_bindgen = ["dep:wasm-bindgen", "dep:wasm-bindgen-futures"] sink = ["dep:futures-sink", "futures-util/sink"] [[example]] name = "basic_tokio" required-features = ["tokio", "macros"] [[example]] name = "basic_async_std" required-features = ["async_std", "macros"] [[example]] name = "basic_smol" path = "examples/basic_smol.rs" required-features = ["smol", "macros"] [[example]] name = "interleaved_messages" required-features = ["smol", "macros"] [[example]] name = "message_stealing_multiple_actors" required-features = ["smol", "macros"] [[example]] name = "crude_bench" required-features = ["tokio", "macros"] [[example]] name = "backpressure" required-features = ["tokio", "macros"] [[example]] name = "address_sink" required-features = ["tokio", "tokio/full", "sink", "macros"] [[example]] name = "send_interval" required-features = ["tokio", "tokio/full", "macros"] [[example]] name = "scoped_actor_task" required-features = ["tokio", "macros"] [[example]] name = "custom_event_loop" required-features = ["macros"] [[example]] name = "manual_actor_impl" required-features = ["tokio"] [[test]] name = "basic" required-features = ["tokio", "macros"] [[test]] name = "public_api" required-features = ["tokio", "macros"] [[test]] name = "instrumentation" required-features = ["tokio", "instrumentation", "macros"] [package.metadata.docs.rs] features = ["async_std", "smol", "tokio", "wasm_bindgen"] rustdoc-args = ["--cfg", "docsrs"] [[bench]] name = "throughput" harness = false