Skip to main content

ServerExecutionResult

Struct ServerExecutionResult 

Source
pub struct ServerExecutionResult {
Show 23 fields pub success: bool, pub flow_name: String, pub source_file: String, pub backend: String, pub steps_executed: usize, pub latency_ms: u64, pub tokens_input: u64, pub tokens_output: u64, pub anchor_checks: usize, pub anchor_breaches: usize, pub errors: usize, pub type_errors: Vec<String>, pub step_names: Vec<String>, pub step_results: Vec<String>, pub trace_id: u64, pub effect_policies: Vec<(String, String)>, pub enforcement_summaries: Vec<(String, EnforcementSummaryWire)>, pub runtime_warnings: Vec<RuntimeWarning>, pub provenance_events: Vec<String>, pub blame_attribution: Option<BlameContext>, pub epistemic_envelopes: Vec<EpistemicEnvelope>, pub error: Option<String>, pub temporal_context: Option<TemporalRecord>,
}
Expand description

Server-side execution result.

§Fase 39.b — promoted from struct to pub struct (and all fields to pub) so the new crate::wire_envelope::FlowEnvelope module can consume it as the converter input. Pre-39.b this type was internal to axon_server; v2.0.0 elevates it to a crate-public shape because it is the canonical input of the wire envelope builder. It is intentionally NOT part of the JSON wire (the FlowEnvelope is); it remains a runtime-internal aggregation step.

Fields§

§success: bool§flow_name: String§source_file: String§backend: String§steps_executed: usize§latency_ms: u64§tokens_input: u64§tokens_output: u64§anchor_checks: usize§anchor_breaches: usize§errors: usize§type_errors: Vec<String>

§Fase 120.f — the type errors, in words.

server_execute type-checks and then executes anyway (“non-fatal for execution”), and until this field existed it collected the diagnostics and threw them away: the caller received success: false and errors: 1, with no way to learn what the 1 was. Every other consumer of the type-checker surfaces its messages — axon check, axon compile, axon run, /deploy, /execute/dry-run and flow_inspect all do. This one path was the exception, and it is the path an /v1/execute caller, an MCP client and a SCHEDULED DAEMON take.

A count is not a diagnostic. It tells an adopter that their program is wrong and refuses to say how — while the flow runs to completion and its persist / emit / deliver / notify steps take real outward action.

Empty on the clean path, so the wire shape is unchanged for every program that type-checks.

§step_names: Vec<String>§step_results: Vec<String>§trace_id: u64§effect_policies: Vec<(String, String)>

§Fase 33.e — Per-step stream-effect policies declared in the source. Each entry is (step_name, policy_slug) where slug is one of the closed catalog {drop_oldest, degrade_quality, pause_upstream, fail}. Empty when no step in the flow declares a <stream:<policy>> effect. Surfaced on the SSE axon.complete wire envelope so adopters can observe the policy is bound to runtime.

§enforcement_summaries: Vec<(String, EnforcementSummaryWire)>

§Fase 33.x.d — Per-step EnforcementSummary from the StreamPolicyEnforcer runs. Empty in two cases:

  1. Legacy synchronous path (deleted in 33.z.e) — the enforcer is not run; the wire stays byte-identical with v1.24.0 (D4 byte-compat).
  2. Async streaming path where no step in the flow has a declared <stream:<policy>> effect — the enforcer is not constructed (no policy to enforce); D2 contract. Surfaced on the SSE axon.complete wire envelope so adopters can observe whether the declared policy actually fired in production (a drop_oldest policy that never fires under sustained load is a configuration smell).
§runtime_warnings: Vec<RuntimeWarning>

§Fase 33.x.g — Closed-catalog runtime warnings. Populated only when server_execute_streaming falls back to the legacy synchronous path; carries one axon-W002 streaming-not-supported warning with the specific FallbackMode tag identifying WHY. Empty on the happy (async-streaming-active) path = D4 byte-compat preserved (wire field elided when empty).

§provenance_events: Vec<String>

§Fase 39.c.y — semantic provenance events from the runtime walk (retrieve:<store>, shield:<name>, mutate:<store>, etc.). Merged into the FlowEnvelope.provenance_chain by the converter. Empty for flows with no taxonomy-participating steps.

§blame_attribution: Option<BlameContext>

§Fase 39.c.z — surfaced blame attribution when the flow proceeded on degraded posture (anchor breach / shield rejection / store breach / backend soft-fail / type mismatch). None on clean happy path; the converter writes this slot into the wire envelope’s blame_attribution field verbatim.

§epistemic_envelopes: Vec<EpistemicEnvelope>

§Fase 55.b — per-tool epistemic envelopes (base, scope, confidence) for every flow-level use <Tool> whose tool declares an epistemic:<level> effect. Propagated from the runner’s IR-derived capture and written into FlowEnvelope.epistemic_envelopes by the converter; the streaming path derives the identical set via resolve_epistemic_envelopes_for_flow. Empty (and elided from the wire) for flows that dispatch no epistemic-annotated tool.

§error: Option<String>

§Fase 65.F — the HONEST hard-failure detail when a node’s DispatchError aborted the non-streaming flow (a failing persist/mutate/purge store write, a backend error, etc.): Some("flow 'F' failed at persist into 'S': <cause>"), naming the failing node + the underlying cause. Byte-parity with the streaming dispatcher’s FlowError.error (§37.e/D6). None on the clean path; the converter writes this slot into FlowEnvelope.error verbatim and counts it as one errors so the wire envelope’s certainty bounds to the derived ceiling. Closes the §65.E.2 silent-abort regression (a pre-insert store failure used to present as success:false + empty result + zero diagnostic). Elided from the wire when None.

§temporal_context: Option<TemporalRecord>

§Fase 91.b — the run’s temporal record when any step rendered a declared now: (captured_utc + tzdb_version + zones — the replayability triple of time_is_an_explicit_input, §71/§91). The converter writes it into FlowEnvelope.temporal_context verbatim. None — and elided from the wire — for every now:-less flow, so every pre-§91 envelope stays byte-identical.

Trait Implementations§

Source§

impl Clone for ServerExecutionResult

Source§

fn clone(&self) -> ServerExecutionResult

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for ServerExecutionResult

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Serialize for ServerExecutionResult

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> PolicyExt for T
where T: ?Sized,

Source§

fn and<P, B, E>(self, other: P) -> And<T, P>
where T: Sized + Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns Action::Follow only if self and other return Action::Follow. Read more
Source§

fn or<P, B, E>(self, other: P) -> Or<T, P>
where T: Sized + Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns Action::Follow if either self or other returns Action::Follow. Read more
Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V

Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more