pub struct InMemoryCheckpointStorage { /* private fields */ }Expand description
In-memory checkpoint storage for testing and development.
Implementations§
Source§impl InMemoryCheckpointStorage
impl InMemoryCheckpointStorage
Sourcepub fn new() -> InMemoryCheckpointStorage
pub fn new() -> InMemoryCheckpointStorage
Create empty in-memory storage.
Trait Implementations§
Source§impl CheckpointStorage for InMemoryCheckpointStorage
impl CheckpointStorage for InMemoryCheckpointStorage
Source§fn save<'life0, 'async_trait>(
&'life0 self,
checkpoint: WorkflowCheckpoint,
) -> Pin<Box<dyn Future<Output = Result<String, Error>> + Send + 'async_trait>>where
'life0: 'async_trait,
InMemoryCheckpointStorage: 'async_trait,
fn save<'life0, 'async_trait>(
&'life0 self,
checkpoint: WorkflowCheckpoint,
) -> Pin<Box<dyn Future<Output = Result<String, Error>> + Send + 'async_trait>>where
'life0: 'async_trait,
InMemoryCheckpointStorage: 'async_trait,
Persist a checkpoint, returning its id.
Source§fn load<'life0, 'life1, 'async_trait>(
&'life0 self,
checkpoint_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<WorkflowCheckpoint>, Error>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
InMemoryCheckpointStorage: 'async_trait,
fn load<'life0, 'life1, 'async_trait>(
&'life0 self,
checkpoint_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<WorkflowCheckpoint>, Error>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
InMemoryCheckpointStorage: 'async_trait,
Load a checkpoint by id, or
None if it does not exist.Source§fn list<'life0, 'life1, 'async_trait>(
&'life0 self,
workflow_id: Option<&'life1 str>,
) -> Pin<Box<dyn Future<Output = Result<Vec<WorkflowCheckpoint>, Error>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
InMemoryCheckpointStorage: 'async_trait,
fn list<'life0, 'life1, 'async_trait>(
&'life0 self,
workflow_id: Option<&'life1 str>,
) -> Pin<Box<dyn Future<Output = Result<Vec<WorkflowCheckpoint>, Error>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
InMemoryCheckpointStorage: 'async_trait,
List checkpoints, optionally filtered by workflow id.
Source§fn delete<'life0, 'life1, 'async_trait>(
&'life0 self,
checkpoint_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<bool, Error>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
InMemoryCheckpointStorage: 'async_trait,
fn delete<'life0, 'life1, 'async_trait>(
&'life0 self,
checkpoint_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<bool, Error>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
InMemoryCheckpointStorage: 'async_trait,
Delete a checkpoint by id, returning whether it existed.
Source§impl Clone for InMemoryCheckpointStorage
impl Clone for InMemoryCheckpointStorage
Source§fn clone(&self) -> InMemoryCheckpointStorage
fn clone(&self) -> InMemoryCheckpointStorage
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Default for InMemoryCheckpointStorage
impl Default for InMemoryCheckpointStorage
Source§fn default() -> InMemoryCheckpointStorage
fn default() -> InMemoryCheckpointStorage
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for InMemoryCheckpointStorage
impl RefUnwindSafe for InMemoryCheckpointStorage
impl Send for InMemoryCheckpointStorage
impl Sync for InMemoryCheckpointStorage
impl Unpin for InMemoryCheckpointStorage
impl UnsafeUnpin for InMemoryCheckpointStorage
impl UnwindSafe for InMemoryCheckpointStorage
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