pub struct GroupCommitWal { /* private fields */ }Expand description
Group commit WAL writer
Implementations§
Source§impl GroupCommitWal
impl GroupCommitWal
Sourcepub async fn write(&self, data: Bytes) -> Result<WriteResult>
pub async fn write(&self, data: Bytes) -> Result<WriteResult>
Write a record to the WAL (async, batched)
Sourcepub async fn write_with_type(
&self,
data: Bytes,
record_type: RecordType,
) -> Result<WriteResult>
pub async fn write_with_type( &self, data: Bytes, record_type: RecordType, ) -> Result<WriteResult>
Write a record with specific type
Sourcepub async fn write_batch(&self, records: Vec<Bytes>) -> Result<Vec<WriteResult>>
pub async fn write_batch(&self, records: Vec<Bytes>) -> Result<Vec<WriteResult>>
Write a batch of records atomically
Sourcepub fn current_lsn(&self) -> u64
pub fn current_lsn(&self) -> u64
Get current LSN
Sourcepub fn stats(&self) -> WalStatsSnapshot
pub fn stats(&self) -> WalStatsSnapshot
Get WAL statistics
Auto Trait Implementations§
impl !Freeze for GroupCommitWal
impl !RefUnwindSafe for GroupCommitWal
impl Send for GroupCommitWal
impl Sync for GroupCommitWal
impl Unpin for GroupCommitWal
impl !UnwindSafe for GroupCommitWal
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more