Struct FileJournalSink
pub struct FileJournalSink { /* private fields */ }Expand description
Durable JournalSink writing one JSON object per line (JSONL).
Writes are buffered behind a parking_lot::Mutex and flushed at least
every second and on drop. I/O errors are logged (via tracing::warn! when
the tracing-support feature is enabled) — journaling never panics a
state write.
{"sequence":1,"key":"app:last_city","old":null,"new":"London","origin":"set","timestamp_ms":1718000000000,"delta":false}Implementations§
§impl FileJournalSink
impl FileJournalSink
Trait Implementations§
§impl JournalSink for FileJournalSink
impl JournalSink for FileJournalSink
§fn write(&self, m: &StateMutation)
fn write(&self, m: &StateMutation)
Persist one mutation. Must not panic; log errors internally.
Auto Trait Implementations§
impl !Freeze for FileJournalSink
impl !RefUnwindSafe for FileJournalSink
impl Send for FileJournalSink
impl Sync for FileJournalSink
impl Unpin for FileJournalSink
impl UnwindSafe for FileJournalSink
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