pub struct InMemoryRuntimeStore { /* private fields */ }Implementations§
Source§impl InMemoryRuntimeStore
impl InMemoryRuntimeStore
pub fn with_journal(self, journal: Arc<dyn RuntimeEventJournalPort>) -> Self
pub async fn snapshot_events(&self) -> Vec<RuntimeEvent>
Trait Implementations§
Source§impl Clone for InMemoryRuntimeStore
impl Clone for InMemoryRuntimeStore
Source§fn clone(&self) -> InMemoryRuntimeStore
fn clone(&self) -> InMemoryRuntimeStore
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl CommandDedupPort for InMemoryRuntimeStore
impl CommandDedupPort for InMemoryRuntimeStore
Source§fn first_seen<'life0, 'life1, 'async_trait>(
&'life0 self,
command_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<bool, CamelError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn first_seen<'life0, 'life1, 'async_trait>(
&'life0 self,
command_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<bool, CamelError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Returns true when the command ID is seen for the first time.
Returns false when the command ID was already processed/reserved.
Source§fn forget_seen<'life0, 'life1, 'async_trait>(
&'life0 self,
command_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<(), CamelError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn forget_seen<'life0, 'life1, 'async_trait>(
&'life0 self,
command_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<(), CamelError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Remove command ID reservation/marker.
Used as compensation when command execution fails.
Source§impl Default for InMemoryRuntimeStore
impl Default for InMemoryRuntimeStore
Source§impl ProjectionStorePort for InMemoryRuntimeStore
impl ProjectionStorePort for InMemoryRuntimeStore
fn upsert_status<'life0, 'async_trait>(
&'life0 self,
status: RouteStatusProjection,
) -> Pin<Box<dyn Future<Output = Result<(), CamelError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn get_status<'life0, 'life1, 'async_trait>(
&'life0 self,
route_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<RouteStatusProjection>, CamelError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn list_statuses<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<RouteStatusProjection>, CamelError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn remove_status<'life0, 'life1, 'async_trait>(
&'life0 self,
route_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<(), CamelError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Source§impl RouteRepositoryPort for InMemoryRuntimeStore
impl RouteRepositoryPort for InMemoryRuntimeStore
fn load<'life0, 'life1, 'async_trait>(
&'life0 self,
route_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<RouteRuntimeAggregate>, CamelError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn save<'life0, 'async_trait>(
&'life0 self,
aggregate: RouteRuntimeAggregate,
) -> Pin<Box<dyn Future<Output = Result<(), CamelError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn save_if_version<'life0, 'async_trait>(
&'life0 self,
aggregate: RouteRuntimeAggregate,
expected_version: u64,
) -> Pin<Box<dyn Future<Output = Result<(), CamelError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn delete<'life0, 'life1, 'async_trait>(
&'life0 self,
route_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<(), CamelError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Source§impl RuntimeUnitOfWorkPort for InMemoryRuntimeStore
impl RuntimeUnitOfWorkPort for InMemoryRuntimeStore
Source§fn persist_upsert<'life0, 'life1, 'async_trait>(
&'life0 self,
aggregate: RouteRuntimeAggregate,
expected_version: Option<u64>,
projection: RouteStatusProjection,
events: &'life1 [RuntimeEvent],
) -> Pin<Box<dyn Future<Output = Result<(), CamelError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn persist_upsert<'life0, 'life1, 'async_trait>(
&'life0 self,
aggregate: RouteRuntimeAggregate,
expected_version: Option<u64>,
projection: RouteStatusProjection,
events: &'life1 [RuntimeEvent],
) -> Pin<Box<dyn Future<Output = Result<(), CamelError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Atomically persist aggregate + projection + events for an upsert transition.
Source§fn persist_delete<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
route_id: &'life1 str,
events: &'life2 [RuntimeEvent],
) -> Pin<Box<dyn Future<Output = Result<(), CamelError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn persist_delete<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
route_id: &'life1 str,
events: &'life2 [RuntimeEvent],
) -> Pin<Box<dyn Future<Output = Result<(), CamelError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Atomically persist delete transition (remove aggregate/projection + append events).
Auto Trait Implementations§
impl Freeze for InMemoryRuntimeStore
impl !RefUnwindSafe for InMemoryRuntimeStore
impl Send for InMemoryRuntimeStore
impl Sync for InMemoryRuntimeStore
impl Unpin for InMemoryRuntimeStore
impl UnsafeUnpin for InMemoryRuntimeStore
impl !UnwindSafe for InMemoryRuntimeStore
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