compio-runtime
High-level runtime for compio.
This crate provides the async runtime (executor) that coordinates task execution with the low-level driver (proactor). It implements a thread-per-core model.
Usage
The recommended way is to use main macro with compio's macros feature, but you can also use the runtime directly by enabling the runtime feature:
Example:
use Runtime;
let runtime = new.unwrap;
runtime.block_on;
Configuration
The runtime can be configured using the RuntimeBuilder:
use RuntimeBuilder;
use ProactorBuilder;
let mut proactor = new;
// Configure proactor here, e.g.
proactor.capacity;
let runtime = new
.with_proactor
// Configure other options here
.build
.unwrap;
runtime.block_on;