pub enum CheckpointData {
SessionStart {
at: String,
version: u32,
session: String,
started_at: String,
invocation: u32,
},
SessionEnd {
at: String,
outcome: String,
error: Option<String>,
},
PhaseDeclared {
at: String,
identity: PhaseIdentity,
skip_eligible: bool,
},
PhaseStarted {
at: String,
identity: PhaseIdentity,
},
PhaseProgress {
at: String,
identity: PhaseIdentity,
op_counts: OpCounts,
cursor_state: Option<Value>,
},
PhaseCompleted {
at: String,
identity: PhaseIdentity,
duration_secs: f64,
op_counts: OpCounts,
},
PhaseFailed {
at: String,
identity: PhaseIdentity,
error: String,
op_counts: Option<OpCounts>,
},
PhaseHash {
at: String,
identity: PhaseIdentity,
hash_hex: String,
params_consumed: Option<String>,
},
ScopeEnter {
at: String,
kind: String,
coords: BTreeMap<String, Value>,
path: Vec<BTreeMap<String, Value>>,
},
ScopeExit {
at: String,
kind: String,
coords: BTreeMap<String, Value>,
path: Vec<BTreeMap<String, Value>>,
outcome: String,
},
}Expand description
One record in the JSONL event log. Tagged on type so the
stream is forward-extensible: adding a new variant is a
no-op for older readers (they ignore unknown types per
SRD-44a §“Reader behaviour”).
Variants§
SessionStart
First line of every fresh invocation’s section. Resume
increments invocation and writes a fresh session_start
to continue the same JSONL — no separate file rotation.
Fields
SessionEnd
Written when the workload completes. Optional — its absence means the invocation was interrupted, which the resume planner uses to distinguish clean exit from crash.
Fields
PhaseDeclared
One per phase per invocation, written during pre-map. Carries identity and eligibility flags so the reader can build the planned phase index without reading the workload YAML.
PhaseStarted
Mark a declared phase as Running.
PhaseProgress
Periodic op-count + cursor-state update for a Running
phase. Replaces the in-place mutation of
PhaseEntry::op_counts and cursor_state from SRD-44.
The reader keeps only the most recent progress
record per (identity, current invocation) when folding.
Fields
identity: PhaseIdentityPhaseCompleted
Phase reached the Completed state. Per SRD-44 §“Status Completed is load-bearing”, this is the call that makes the phase eligible to skip on a future resume.
PhaseFailed
Phase failed terminally. The error message is preserved for resume diagnostics.
PhaseHash
Update on a previously-declared phase: bind the
program-canonical hash. Called once per phase the first
time it compiles. Folds into the existing entry’s
identity so a future resume can detect program drift via
PhaseIdentity::matches_full.
Fields
identity: PhaseIdentityScopeEnter
Reserved for SRD-44a Push 3. The reader already understands these variants so the writer can emit them in a future patch without a schema bump.
ScopeExit
Reserved for SRD-44a Push 3.
Implementations§
Source§impl CheckpointData
impl CheckpointData
Sourcepub fn at(&self) -> &str
pub fn at(&self) -> &str
RFC 3339 timestamp this event was tagged with. All variants carry one; the helper avoids a match in the fold loop.
Sourcepub fn event_type(&self) -> Option<EventType>
pub fn event_type(&self) -> Option<EventType>
The lifecycle kind-tag this durable record corresponds
to, tying an on-disk CheckpointData record back to
the in-memory crate::lifecycle::EventType that the
readout binder fires on. None for records that have no
lifecycle fire point — structural / metadata records
(a pre-map PhaseDeclared declaration, a PhaseHash
binding) are written to the log but never fire a readout
slot, so they have no kind-tag.
Trait Implementations§
Source§impl Clone for CheckpointData
impl Clone for CheckpointData
Source§impl Debug for CheckpointData
impl Debug for CheckpointData
Source§impl<'de> Deserialize<'de> for CheckpointData
impl<'de> Deserialize<'de> for CheckpointData
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 Forget for CheckpointData
impl Freeze for CheckpointDatawhere
*const u8 is !null: Freeze,
PhantomData<u8>: Freeze,
PhantomData<PathSegment>: Freeze,
PhantomData<Value>: Freeze,
PhantomData<usize>: Freeze,
PhantomData<Bucket<String, Value>>: Freeze,
*const LeafNode<String, Value> is !null: Freeze,
PhantomData<(Owned, LeafOrInternal)>: Freeze,
PhantomData<Box<(String, Value)>>: Freeze,
PhantomData<BTreeMap<String, Value>>: Freeze,
impl Move for CheckpointData
impl RefUnwindSafe for CheckpointData
impl Send for CheckpointData
impl Sync for CheckpointData
impl Unpin for CheckpointData
impl UnsafeUnpin for CheckpointDatawhere
*const u8 is !null: UnsafeUnpin,
PhantomData<u8>: UnsafeUnpin,
PhantomData<PathSegment>: UnsafeUnpin,
PhantomData<Value>: UnsafeUnpin,
PhantomData<usize>: UnsafeUnpin,
PhantomData<Bucket<String, Value>>: UnsafeUnpin,
*const LeafNode<String, Value> is !null: UnsafeUnpin,
PhantomData<(Owned, LeafOrInternal)>: UnsafeUnpin,
PhantomData<Box<(String, Value)>>: UnsafeUnpin,
PhantomData<BTreeMap<String, Value>>: UnsafeUnpin,
impl UnwindSafe for CheckpointData
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