pub struct ExecutionLifecycle { /* private fields */ }Expand description
Sole owner of task admission, ordered completion, and exact-once side effects.
Implementations§
Source§impl ExecutionLifecycle
impl ExecutionLifecycle
pub fn global() -> &'static Self
pub fn with_triage(triage: TriageEngine) -> Self
pub fn with_components(triage: TriageEngine, value_gate: ValueGate) -> Self
pub fn begin( &self, request: ToolRequest, runtime: RuntimeContext, entitlements: ProductEntitlements, ) -> TaskContext
pub async fn run<D>(
&self,
request: ToolRequest,
runtime: RuntimeContext,
entitlements: ProductEntitlements,
driver: D,
) -> Result<D::Output, LifecycleRunError<D::Error>>where
D: ExecutionDriver,
Sourcepub async fn run_with_task_identity<D>(
&self,
request: ToolRequest,
runtime: RuntimeContext,
entitlements: ProductEntitlements,
driver: D,
identity: Option<AdmittedTaskIdentity>,
) -> Result<D::Output, LifecycleRunError<D::Error>>where
D: ExecutionDriver,
pub async fn run_with_task_identity<D>(
&self,
request: ToolRequest,
runtime: RuntimeContext,
entitlements: ProductEntitlements,
driver: D,
identity: Option<AdmittedTaskIdentity>,
) -> Result<D::Output, LifecycleRunError<D::Error>>where
D: ExecutionDriver,
Preserve the sole lifecycle owner while accepting an explicit host identity.
pub fn complete( &self, context: &TaskContext, observation: CompletionObservation, ) -> LifecycleOutcome
Sourcepub fn complete_once(
&self,
context: &TaskContext,
observation: CompletionObservation,
) -> Option<LifecycleOutcome>
pub fn complete_once( &self, context: &TaskContext, observation: CompletionObservation, ) -> Option<LifecycleOutcome>
Complete an open run and report whether this call owned finalization.
Compatibility adapters use this to preserve their historic duplicate
suppression while the lifecycle still returns a stable cached outcome
through Self::complete.
pub fn profile_for_session(&self, session_id: &str) -> Option<TaskProfileLocal>
pub fn assessment_for(&self, task_id: &str) -> Option<ValueAssessment>
pub fn outcome_for(&self, task_id: &str) -> Option<LifecycleOutcome>
Trait Implementations§
Source§impl Clone for ExecutionLifecycle
impl Clone for ExecutionLifecycle
Source§impl Debug for ExecutionLifecycle
impl Debug for ExecutionLifecycle
Auto Trait Implementations§
impl !RefUnwindSafe for ExecutionLifecycle
impl !UnwindSafe for ExecutionLifecycle
impl Forget for ExecutionLifecycle
impl Freeze for ExecutionLifecycle
impl Move for ExecutionLifecycle
impl Send for ExecutionLifecycle
impl Sync for ExecutionLifecycle
impl Unpin for ExecutionLifecycle
impl UnsafeUnpin for ExecutionLifecycle
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<A, B, T> HttpServerConnExec<A, B> for Twhere
B: Body,
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