pub struct Injector<IO: Io> { /* private fields */ }Expand description
The injector takes frames and injects them in the wal.
Implementations§
Source§impl<IO: Io> Injector<IO>
impl<IO: Io> Injector<IO>
pub fn new(wal: Arc<SharedWal<IO>>, buffer_capacity: usize) -> Result<Self>
pub fn set_durable(&mut self, durable_frame_no: u64)
pub fn current_durable(&self) -> u64
pub fn maybe_begin_txn(&mut self) -> Result<()>
pub async fn insert_frame(&mut self, frame: Box<Frame>) -> Result<Option<u64>>
pub async fn flush(&mut self, size_after: Option<u32>) -> Result<()>
pub fn rollback(&mut self)
Auto Trait Implementations§
impl<IO> !Freeze for Injector<IO>
impl<IO> !RefUnwindSafe for Injector<IO>
impl<IO> Send for Injector<IO>
impl<IO> Sync for Injector<IO>
impl<IO> Unpin for Injector<IO>
impl<IO> !UnwindSafe for Injector<IO>
Blanket Implementations§
§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
§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 moreCreates a shared type from an unshared type.