Expand description
Cancel-safe async io_uring read backend for RustFS (rustfs/backlog#894, hardened per the #1048/#1051 audit).
This crate proves and enforces the ownership model any production io_uring integration in RustFS must follow:
- The read buffer and the file handle are owned by the driver’s pending (orphan) table from SQE submission until the CQE arrives. The kernel may write into the buffer at any point in that window, so nothing else is allowed to free or move its heap allocation.
- Dropping the caller-side future only abandons the result. It never
touches the buffer. Optionally it submits
IORING_OP_ASYNC_CANCELto accelerate the CQE; reclamation still happens only at the CQE. - Driver shutdown cancels all in-flight ops and drains the ring to
in_flight == 0(with a bounded escape hatch) before the ring is unmapped.
Status: read path only, Linux only. The driver supports positioned buffered
reads, O_DIRECT reads with internal alignment, sharded rings, async
backpressure, eventfd-driven reaping, graceful restricted-environment
detection, and bounded shutdown drain. The write path is intentionally out
of scope for 0.1.0; see the
design notes
for the invariant details.
Structs§
- Stats
Snapshot - Point-in-time copy of the driver counters.
- Uring
Driver
Enums§
- Probe
Failure - Why the probe refused to start the io_uring driver.