pub struct OpenOptions {
pub lock_timeout_ms: u32,
}Expand description
Knobs for kit-level database opens.
Default is lock_timeout_ms = 0 (fail-fast), matching the historical
Database::open behavior and preserving backwards compatibility.
Fields§
§lock_timeout_ms: u32How long to wait for the cross-process exclusive lock on
<dir>/_meta/.lock to become available, in milliseconds. 0
preserves the fail-fast behavior. Non-zero enables
SQLite-style busy_timeout semantics: 1ms → 10ms → 50ms
backoff with a hard deadline at lock_timeout_ms.
Implementations§
Source§impl OpenOptions
impl OpenOptions
Sourcepub fn with_lock_timeout_ms(self, ms: u32) -> Self
pub fn with_lock_timeout_ms(self, ms: u32) -> Self
Set OpenOptions::lock_timeout_ms. 0 keeps the fail-fast default;
SQLite-style applications typically pick 1_000 – 5_000ms.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for OpenOptions
impl RefUnwindSafe for OpenOptions
impl Send for OpenOptions
impl Sync for OpenOptions
impl Unpin for OpenOptions
impl UnsafeUnpin for OpenOptions
impl UnwindSafe for OpenOptions
Blanket Implementations§
impl<T> Allocation for T
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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