pub struct MemoryCheckpointer<S: StateSchema> { /* private fields */ }Expand description
In-memory checkpointer for development
Implementations§
Source§impl<S: StateSchema> MemoryCheckpointer<S>
impl<S: StateSchema> MemoryCheckpointer<S>
Trait Implementations§
Source§impl<S: StateSchema> Checkpointer<S> for MemoryCheckpointer<S>
impl<S: StateSchema> Checkpointer<S> for MemoryCheckpointer<S>
Source§fn save<'life0, 'life1, 'async_trait>(
&'life0 self,
state: &'life1 S,
recursion_count: usize,
) -> Pin<Box<dyn Future<Output = GraphResult<String>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn save<'life0, 'life1, 'async_trait>(
&'life0 self,
state: &'life1 S,
recursion_count: usize,
) -> Pin<Box<dyn Future<Output = GraphResult<String>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Insert a new checkpoint, recording how much of the recursion budget had
been consumed by the run at that point (M6).
fn load<'life0, 'life1, 'async_trait>(
&'life0 self,
checkpoint_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = GraphResult<S>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Source§fn list<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = GraphResult<Vec<String>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn list<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = GraphResult<Vec<String>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
List checkpoint ids, ordered from oldest to most recent (H5).
Source§fn last<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = GraphResult<Option<(S, usize)>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn last<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = GraphResult<Option<(S, usize)>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
State and recursion budget of the most recently saved checkpoint.
fn delete<'life0, 'life1, 'async_trait>(
&'life0 self,
checkpoint_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = GraphResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Source§impl<S: StateSchema> Default for MemoryCheckpointer<S>
impl<S: StateSchema> Default for MemoryCheckpointer<S>
Auto Trait Implementations§
impl<S> !Freeze for MemoryCheckpointer<S>
impl<S> !RefUnwindSafe for MemoryCheckpointer<S>
impl<S> !UnwindSafe for MemoryCheckpointer<S>
impl<S> Send for MemoryCheckpointer<S>
impl<S> Sync for MemoryCheckpointer<S>
impl<S> Unpin for MemoryCheckpointer<S>
impl<S> UnsafeUnpin for MemoryCheckpointer<S>
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