Struct Snapshot
pub struct Snapshot;Expand description
Full snapshot isolation. The default.
Reads never block and never abort. Writes abort with
crate::Error::WriteConflict if another transaction committed a change
to the same key after this transaction’s snapshot (first-committer-wins).
Permits write skew.
Trait Implementations§
impl Copy for Snapshot
§impl IsolationLevel for Snapshot
impl IsolationLevel for Snapshot
§const REFRESH_SNAPSHOT_PER_STATEMENT: bool = false
const REFRESH_SNAPSHOT_PER_STATEMENT: bool = false
Whether a fresh snapshot is taken before each statement rather than once
at
begin.§const FIRST_COMMITTER_WINS: bool = true
const FIRST_COMMITTER_WINS: bool = true
Whether the engine must check for write-write conflicts against versions
committed after this transaction’s snapshot. False only for
ReadCommitted, which re-reads the latest version before writing.§const VALIDATES_READS: bool = false
const VALIDATES_READS: bool = false
Whether reads are recorded and re-checked at commit. True only for
Serializable. Read moreAuto Trait Implementations§
impl Freeze for Snapshot
impl RefUnwindSafe for Snapshot
impl Send for Snapshot
impl Sync for Snapshot
impl Unpin for Snapshot
impl UnsafeUnpin for Snapshot
impl UnwindSafe for Snapshot
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