pub enum WroteCommit {
Yes,
No,
}Expand description
Whether WalRecorder::commit actually wrote a TxCommit to the
log. Read-only queries — those that never trigger
MutationRecorder::record — return WroteCommit::No so the host
can skip the surrounding flush() and avoid a per-query fsync
just to record an empty transaction.
Variants§
Yes
A TxBegin had been lazily allocated and was paired with a
matching TxCommit. Caller should flush() (under PerCommit).
No
No mutation events fired during the query, so neither TxBegin
nor TxCommit was appended. Caller can skip flush() entirely.
Trait Implementations§
Source§impl Clone for WroteCommit
impl Clone for WroteCommit
Source§fn clone(&self) -> WroteCommit
fn clone(&self) -> WroteCommit
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 Debug for WroteCommit
impl Debug for WroteCommit
Source§impl PartialEq for WroteCommit
impl PartialEq for WroteCommit
impl Copy for WroteCommit
impl Eq for WroteCommit
impl StructuralPartialEq for WroteCommit
Auto Trait Implementations§
impl Freeze for WroteCommit
impl RefUnwindSafe for WroteCommit
impl Send for WroteCommit
impl Sync for WroteCommit
impl Unpin for WroteCommit
impl UnsafeUnpin for WroteCommit
impl UnwindSafe for WroteCommit
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