pub struct ParallelDispatchConfig {
pub mode: ParallelMode,
pub max_concurrency: usize,
}Expand description
Configuration for parallel tool dispatch.
Defaults to ParallelMode::Sequential (off) with a
max_concurrency of 8. Parallel dispatch is strictly opt-in — set
mode to Parallel to enable.
§Example
use loopctl::config::{ParallelDispatchConfig, ParallelMode};
let dispatch = ParallelDispatchConfig { mode: ParallelMode::Parallel, max_concurrency: 4 };
assert_eq!(dispatch.max_concurrency, 4);Fields§
§mode: ParallelModeSequential vs parallel dispatch.
Defaults to ParallelMode::Sequential.
Set to ParallelMode::Parallel to enable concurrent dispatch of
independent, concurrency-safe tool calls.
See ParallelMode for the observer/detection ordering
implications of each variant.
max_concurrency: usizeMaximum number of tool calls executing at once under parallel mode.
Defaults to 8. Clamped to [1, eligible_count] at dispatch time (a
3-call batch never tries to acquire 8 permits). Setting this to 1
makes “parallel” mode behave like sequential — useful for debugging
(same code path, no concurrency). Must be at least 1.
Trait Implementations§
Source§impl Clone for ParallelDispatchConfig
impl Clone for ParallelDispatchConfig
Source§fn clone(&self) -> ParallelDispatchConfig
fn clone(&self) -> ParallelDispatchConfig
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more