pub struct ActorChildRunner { /* private fields */ }Expand description
Spawns and drives a child session as an independent actor: a bamboo-subagent worker process.
Implementations§
Source§impl ActorChildRunner
impl ActorChildRunner
pub fn new( agent_id: String, worker_bin: PathBuf, worker_args: Vec<String>, fabric_dir: PathBuf, executor: ExecutorSpec, credentials: Vec<ScopedCredential>, default_provider: String, max_concurrent: usize, ) -> Self
Sourcepub fn with_approval_decider(
self,
decider: Arc<dyn ChildApprovalDecider>,
) -> Self
pub fn with_approval_decider( self, decider: Arc<dyn ChildApprovalDecider>, ) -> Self
Wire the host-side decider for child gated-tool approval requests (Phase 2). Without this the host fail-closed DENYs every request.
Trait Implementations§
Source§impl ExternalChildRunner for ActorChildRunner
impl ExternalChildRunner for ActorChildRunner
Source§fn should_handle<'life0, 'life1, 'async_trait>(
&'life0 self,
session: &'life1 Session,
) -> Pin<Box<dyn Future<Output = bool> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn should_handle<'life0, 'life1, 'async_trait>(
&'life0 self,
session: &'life1 Session,
) -> Pin<Box<dyn Future<Output = bool> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Returns true if this runner should handle the given child session.
Source§fn set_escalation_bridge(&self, bridge: Option<HostBridge>)
fn set_escalation_bridge(&self, bridge: Option<HostBridge>)
Bind this runner’s per-run escalation host bridge (#68). A nested worker’s
run() installs its OWN host bridge here so the runner can hand it to each
grandchild’s drive() AT SPAWN time (captured into the drive task, not read
later), letting the grandchild re-proxy a non-bypass approval request UP to
its parent run for its whole lifetime — even when it outlives the run that
spawned it. Default no-op for runners that don’t escalate (e.g. A2A).Source§fn execute_external_child<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
session: &'life1 mut Session,
job: &'life2 SpawnJob,
event_tx: Sender<AgentEvent>,
cancel_token: CancellationToken,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn execute_external_child<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
session: &'life1 mut Session,
job: &'life2 SpawnJob,
event_tx: Sender<AgentEvent>,
cancel_token: CancellationToken,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Execute the child session using an external runtime.
Auto Trait Implementations§
impl !RefUnwindSafe for ActorChildRunner
impl !UnwindSafe for ActorChildRunner
impl Freeze for ActorChildRunner
impl Send for ActorChildRunner
impl Sync for ActorChildRunner
impl Unpin for ActorChildRunner
impl UnsafeUnpin for ActorChildRunner
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