pub struct EffectRecord {
pub tool_output: Option<ToolResultContext>,
pub id: EffectId,
pub key: HandlerKey,
pub kind: EffectKind,
pub outcome: Result<Outcome, ErrorReport>,
pub events: Option<Transcript>,
pub stream_origin: Option<Origin>,
pub parent: Option<EffectId>,
pub scope: Option<Arc<str>>,
}Expand description
One recorded exchange: the effect, who served it, and the answer.
Fields§
§tool_output: Option<ToolResultContext>Explicitly published tool-result metadata, including on errors. Never
inbound authentication values or runtime scopes. None means the tool
did not publish a context before resolving. The wire field is required:
null explicitly records no publication; omission cannot establish
whether an older recorder lost output and is rejected when decoding.
id: EffectIdThe dispatch’s id.
key: HandlerKeyThe handler the effect was routed to.
kind: EffectKindThe effect.
outcome: Result<Outcome, ErrorReport>The answer.
events: Option<Transcript>A streamed dispatch’s items, verbatim, when the recorder was asked
to keep them (EffectLogRecorder::keeping_stream_events); None
otherwise, and the answer is the fold. A replayer re-emits these
when present, so a replayed consumer sees the original fragment
boundaries. They read back through Transcript::parse_prefix.
stream_origin: Option<Origin>Who a streamed dispatch’s reply was from, as its relay stated it before the first item, when the items are kept. A replayer sends it first, so a replayed stream cut short knows its origin.
parent: Option<EffectId>Parent dispatch for a nested handler call, or None for a root dispatch.
scope: Option<Arc<str>>Stable identifier of the dispatching program or run, not a runtime handle.
None when the dispatcher supplied no scope.
Trait Implementations§
Source§impl Clone for EffectRecord
impl Clone for EffectRecord
Source§impl Debug for EffectRecord
impl Debug for EffectRecord
Source§impl<'de> Deserialize<'de> for EffectRecord
impl<'de> Deserialize<'de> for EffectRecord
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Auto Trait Implementations§
impl !RefUnwindSafe for EffectRecord
impl !UnwindSafe for EffectRecord
impl Freeze for EffectRecord
impl Send for EffectRecord
impl Sync for EffectRecord
impl Unpin for EffectRecord
impl UnsafeUnpin for EffectRecord
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
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<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
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> ⓘ
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> ⓘ
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