pub struct InMemoryJournal { /* private fields */ }Implementations§
Source§impl InMemoryJournal
impl InMemoryJournal
Sourcepub fn list_persistence_ids(&self) -> Vec<String>
pub fn list_persistence_ids(&self) -> Vec<String>
List all persistence ids currently stored. Used by the telemetry
JournalAdmin impl.
Sourcepub fn event_count(&self, persistence_id: &str) -> u64
pub fn event_count(&self, persistence_id: &str) -> u64
Number of non-deleted events stored for persistence_id.
Trait Implementations§
Source§impl Default for InMemoryJournal
impl Default for InMemoryJournal
Source§fn default() -> InMemoryJournal
fn default() -> InMemoryJournal
Returns the “default value” for a type. Read more
Source§impl Journal for InMemoryJournal
impl Journal for InMemoryJournal
fn write_messages<'life0, 'async_trait>(
&'life0 self,
messages: Vec<PersistentRepr>,
) -> Pin<Box<dyn Future<Output = Result<(), JournalError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn delete_messages_to<'life0, 'life1, 'async_trait>(
&'life0 self,
persistence_id: &'life1 str,
to_sequence_nr: u64,
) -> Pin<Box<dyn Future<Output = Result<(), JournalError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn replay_messages<'life0, 'life1, 'async_trait>(
&'life0 self,
persistence_id: &'life1 str,
from: u64,
to: u64,
max: u64,
) -> Pin<Box<dyn Future<Output = Result<Vec<PersistentRepr>, JournalError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn highest_sequence_nr<'life0, 'life1, 'async_trait>(
&'life0 self,
pid: &'life1 str,
_from: u64,
) -> Pin<Box<dyn Future<Output = Result<u64, JournalError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Source§fn all_persistence_ids<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<String>, JournalError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn all_persistence_ids<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<String>, JournalError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Distinct persistence ids known to the backend. Default impl
returns empty so backends without an id index opt in.
fn events_by_tag<'life0, 'life1, 'async_trait>(
&'life0 self,
tag: &'life1 str,
from_offset: u64,
max: u64,
) -> Pin<Box<dyn Future<Output = Result<Vec<PersistentRepr>, JournalError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Auto Trait Implementations§
impl !Freeze for InMemoryJournal
impl !RefUnwindSafe for InMemoryJournal
impl Send for InMemoryJournal
impl Sync for InMemoryJournal
impl Unpin for InMemoryJournal
impl UnsafeUnpin for InMemoryJournal
impl UnwindSafe for InMemoryJournal
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