pub struct GovernorConfig {
pub max_model_loads: usize,
pub max_local_stt: usize,
pub max_local_tts: usize,
pub max_remote: usize,
pub max_blocking: usize,
pub max_cpu_threads: usize,
pub max_memory_bytes: u64,
pub queue_timeout: Duration,
pub fail_fast: bool,
}Expand description
Configuration for a ResourceGovernor.
Fields§
§max_model_loads: usize§max_local_stt: usize§max_local_tts: usize§max_remote: usize§max_blocking: usize§max_cpu_threads: usizeTotal Whisper inference threads across concurrent STT jobs.
max_memory_bytes: u64Soft memory reservation budget (bytes).
queue_timeout: DurationMax time to wait for a permit.
fail_fast: boolWhen true, fail immediately if a permit is not free (no wait).
Implementations§
Trait Implementations§
Source§impl Clone for GovernorConfig
impl Clone for GovernorConfig
Source§fn clone(&self) -> GovernorConfig
fn clone(&self) -> GovernorConfig
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for GovernorConfig
impl Debug for GovernorConfig
Auto Trait Implementations§
impl Freeze for GovernorConfig
impl RefUnwindSafe for GovernorConfig
impl Send for GovernorConfig
impl Sync for GovernorConfig
impl Unpin for GovernorConfig
impl UnsafeUnpin for GovernorConfig
impl UnwindSafe for GovernorConfig
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more