pub trait PersistenceStore: Send + Sync {
// Required methods
fn append<'life0, 'async_trait>(
&'life0 self,
envelope: PersistenceEnvelope,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn load<'life0, 'life1, 'async_trait>(
&'life0 self,
trace_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<PersistedTrace>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn resume<'life0, 'life1, 'async_trait>(
&'life0 self,
trace_id: &'life1 str,
resume_from_step: u64,
) -> Pin<Box<dyn Future<Output = Result<ResumeCursor>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn complete<'life0, 'life1, 'async_trait>(
&'life0 self,
trace_id: &'life1 str,
completion: CompletionState,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
}๐Deprecated since 0.7.0: Experimental persistence contract (M148); API may change before stabilization.
Expand description
Persistence abstraction draft for long-running workflow recovery.
This is intentionally minimal and marked experimental while M148 is active.
Required Methodsยง
fn append<'life0, 'async_trait>(
&'life0 self,
envelope: PersistenceEnvelope,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
๐Deprecated since 0.7.0: Experimental persistence contract (M148); API may change before stabilization.
fn load<'life0, 'life1, 'async_trait>(
&'life0 self,
trace_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<PersistedTrace>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
๐Deprecated since 0.7.0: Experimental persistence contract (M148); API may change before stabilization.
fn resume<'life0, 'life1, 'async_trait>(
&'life0 self,
trace_id: &'life1 str,
resume_from_step: u64,
) -> Pin<Box<dyn Future<Output = Result<ResumeCursor>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
๐Deprecated since 0.7.0: Experimental persistence contract (M148); API may change before stabilization.
fn complete<'life0, 'life1, 'async_trait>(
&'life0 self,
trace_id: &'life1 str,
completion: CompletionState,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
๐Deprecated since 0.7.0: Experimental persistence contract (M148); API may change before stabilization.