pub struct BackendDispatcher { /* private fields */ }Expand description
Fallback dispatcher that routes through backend.call_tool().
This provides the same behavior as the old PipelineRunner — it dispatches
to builtins via the backend’s tool registry. Used for background jobs and
scatter/gather workers until full Arc<Kernel> dispatch is wired up.
Limitations compared to the Kernel dispatcher:
- No user-defined tools
- No .kai script resolution
- No async argument evaluation (command substitution in args won’t work)
Implementations§
Source§impl BackendDispatcher
impl BackendDispatcher
Sourcepub fn new(tools: Arc<ToolRegistry>) -> Self
pub fn new(tools: Arc<ToolRegistry>) -> Self
Create a new backend dispatcher with the given tool registry.
Trait Implementations§
Source§impl CommandDispatcher for BackendDispatcher
impl CommandDispatcher for BackendDispatcher
Source§fn dispatch<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
cmd: &'life1 Command,
ctx: &'life2 mut ExecContext,
) -> Pin<Box<dyn Future<Output = Result<ExecResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn dispatch<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
cmd: &'life1 Command,
ctx: &'life2 mut ExecContext,
) -> Pin<Box<dyn Future<Output = Result<ExecResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Dispatch a single command for execution. Read more
Auto Trait Implementations§
impl Freeze for BackendDispatcher
impl !RefUnwindSafe for BackendDispatcher
impl Send for BackendDispatcher
impl Sync for BackendDispatcher
impl Unpin for BackendDispatcher
impl UnsafeUnpin for BackendDispatcher
impl !UnwindSafe for BackendDispatcher
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