ring_promise 0.1.0

A minimal, ergonomic, and thread-friendly abstraction for submission/completion ring-based I/O in Rust.
Documentation
  • Coverage
  • 100%
    32 out of 32 items documented0 out of 27 items with examples
  • Size
  • Source code size: 15.94 kB This is the summed size of all the files inside the crates.io package for this release.
  • Documentation size: 493.55 kB This is the summed size of all files generated by rustdoc for all configured targets
  • Ø build duration
  • this release: 11s Average build duration of successful builds.
  • all releases: 11s Average build duration of successful builds in releases after 2024-10-23.
  • Links
  • crates.io
  • Dependencies
  • Versions
  • Owners
  • Orkking2

ring_promise

A minimal, ergonomic, and thread-friendly abstraction for submission/completion ring-based I/O in Rust.

Features

  • Generic over submission and completion queue entry types
  • Thread-safe sender abstraction
  • Promise-based completion notification
  • Minimal dependencies

Usage

Add to your Cargo.toml:

[dependencies]
ring_promise = "0.1.0"

Example

use ring_promise::{PRingSender, traits::*};
// Define your SQE, CQE, and ring types here...

// let ring = ...;
// let sender = PRingSender::<MySQE, MyCQE>::new::<MySQ, MyCQ, MyRing>(ring);
// let promise = sender.submit(my_entry);
// let result = promise.wait().unwrap(); // Look at the promisery crate for details on handling the promises.

Traits

  • SubmissionQueueEntry: Types that can be submitted to a submission queue.
  • SubmissionQueue: A queue for submission entries.
  • CompletionQueueEntry: Types produced by completion queues.
  • CompletionQueue: A queue for completion entries (iterator).
  • Submitter: Notifies the kernel/system of new submissions.
  • FullRing: Combines submission, completion, and submitter.

License

MIT OR Apache-2.0