pub struct OffloadConfig {
pub max_threads: usize,
pub max_queue: usize,
pub idle_timeout: Duration,
pub target: Duration,
pub interval: Duration,
pub name: String,
}Expand description
Settings of an OffloadPool.
Fields§
§max_threads: usizeMost worker threads (0 = default_threads: 32 per CPU, between 512 and 1024). Threads
start on demand and exit when idle, so a high cap costs nothing until jobs block.
max_queue: usizeMost jobs waiting.
idle_timeout: DurationHow long an idle worker waits before it exits.
target: DurationCoDel sojourn target (raised to four times the jobs’ recent mean run time when that is longer).
interval: DurationCoDel interval.
name: StringWorker thread name.
Trait Implementations§
Source§impl Clone for OffloadConfig
impl Clone for OffloadConfig
Source§impl Debug for OffloadConfig
impl Debug for OffloadConfig
Auto Trait Implementations§
impl Forget for OffloadConfig
impl Freeze for OffloadConfig
impl Move for OffloadConfig
impl RefUnwindSafe for OffloadConfig
impl Send for OffloadConfig
impl Sync for OffloadConfig
impl Unpin for OffloadConfig
impl UnsafeUnpin for OffloadConfig
impl UnwindSafe for OffloadConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more