[package]
name = "compio"
version = "0.12.0"
description = "Completion based async runtime"
categories = ["asynchronous", "filesystem", "network-programming"]
keywords = ["async", "fs", "iocp", "io-uring", "net"]
edition = { workspace = true }
authors = { workspace = true }
readme = { workspace = true }
license = { workspace = true }
repository = { workspace = true }
[package.metadata.docs.rs]
all-features = true
default-target = "x86_64-unknown-linux-gnu"
rustdoc-args = ["--cfg", "docsrs"]
targets = [
"x86_64-pc-windows-gnu",
"x86_64-unknown-linux-gnu",
"x86_64-apple-darwin",
"aarch64-apple-ios",
"aarch64-linux-android",
"x86_64-unknown-dragonfly",
"x86_64-unknown-freebsd",
"x86_64-unknown-illumos",
"x86_64-unknown-netbsd",
"x86_64-unknown-openbsd",
]
[dependencies]
compio-buf = { workspace = true }
compio-driver = { workspace = true }
compio-runtime = { workspace = true, optional = true }
compio-macros = { workspace = true, optional = true }
compio-fs = { workspace = true, optional = true }
compio-io = { workspace = true, optional = true }
compio-net = { workspace = true, optional = true }
compio-signal = { workspace = true, optional = true }
compio-dispatcher = { workspace = true, optional = true }
compio-log = { workspace = true }
compio-tls = { workspace = true, optional = true }
compio-process = { workspace = true, optional = true }
compio-quic = { workspace = true, optional = true }
[dev-dependencies]
compio-buf = { workspace = true, features = ["bumpalo"] }
compio-runtime = { workspace = true, features = ["criterion"] }
compio-macros = { workspace = true }
criterion = { workspace = true, features = ["async_tokio"] }
futures-channel = { workspace = true }
futures-util = { workspace = true }
rand = { workspace = true }
tempfile = { workspace = true }
tokio = { workspace = true, features = [
"fs",
"io-util",
"macros",
"net",
"rt",
] }
[target.'cfg(windows)'.dev-dependencies]
widestring = { workspace = true }
windows-sys = { workspace = true, features = ["Win32_Storage_FileSystem"] }
[target.'cfg(unix)'.dev-dependencies]
nix = { workspace = true, features = ["fs"] }
libc = { workspace = true }
[target.'cfg(target_os = "linux")'.dev-dependencies]
monoio = { version = "0.2.2", default-features = false, features = ["iouring"] }
[features]
default = ["runtime", "io-uring"]
io-uring = [
"compio-driver/io-uring",
"compio-fs?/io-uring",
"compio-net?/io-uring",
"compio-signal?/io-uring",
]
polling = ["compio-driver/polling"]
io = ["dep:compio-io"]
io-compat = ["io", "compio-io/compat", "compio-quic?/io-compat"]
runtime = ["dep:compio-runtime", "dep:compio-fs", "dep:compio-net", "io"]
macros = ["dep:compio-macros", "runtime"]
event = ["compio-runtime/event", "runtime"]
signal = ["dep:compio-signal", "event"]
time = ["compio-runtime/time", "runtime"]
dispatcher = ["dep:compio-dispatcher", "runtime"]
tls = ["dep:compio-tls"]
native-tls = ["tls", "compio-tls/native-tls"]
rustls = ["tls", "compio-tls/rustls"]
process = ["dep:compio-process"]
quic = ["dep:compio-quic"]
h3 = ["quic", "compio-quic/h3"]
all = [
"time",
"macros",
"signal",
"dispatcher",
"native-tls",
"rustls",
"process",
"quic",
"h3",
]
arrayvec = ["compio-buf/arrayvec"]
bumpalo = ["compio-buf/bumpalo"]
bytes = ["compio-buf/bytes"]
criterion = ["compio-runtime?/criterion"]
enable_log = ["compio-log/enable_log"]
allocator_api = ["compio-buf/allocator_api", "compio-io?/allocator_api"]
lazy_cell = ["compio-signal?/lazy_cell"]
linux_pidfd = ["compio-process?/linux_pidfd"]
once_cell_try = ["compio-driver/once_cell_try", "compio-signal?/once_cell_try"]
read_buf = [
"compio-buf/read_buf",
"compio-io?/read_buf",
"compio-tls?/read_buf",
"compio-fs?/read_buf",
]
try_trait_v2 = ["compio-buf/try_trait_v2"]
windows_by_handle = ["compio-fs?/windows_by_handle"]
nightly = [
"allocator_api",
"lazy_cell",
"linux_pidfd",
"once_cell_try",
"read_buf",
"try_trait_v2",
"windows_by_handle",
]
real_blackbox = ["criterion/real_blackbox"]
[[example]]
name = "basic"
required-features = ["macros"]
[[example]]
name = "named_pipe"
required-features = ["macros"]
[[example]]
name = "net"
required-features = ["macros"]
[[example]]
name = "unix"
required-features = ["macros"]
[[example]]
name = "resolve"
required-features = ["macros"]
[[example]]
name = "tick"
required-features = ["time", "signal", "macros"]
[[example]]
name = "dispatcher"
required-features = ["macros", "dispatcher"]
[[bench]]
name = "fs"
harness = false
[[bench]]
name = "net"
harness = false