pub struct LockWaitFacts<'facts> {
pub subject: &'facts str,
pub lock_directory: &'facts Path,
pub holder_pid: Option<i64>,
pub waited: Duration,
pub limit: Duration,
pub place: Option<QueuePlace>,
pub repeat: bool,
}Expand description
What: What one notice of a wait for a lock says. Why: Every wait for a lock names the same facts: what it waits for, who holds it, how long it has waited, where it gives up, and its place when commits queue.
In TS you’d write (pseudocode):
type LockWaitFacts = { subject; lockDirectory; holderPid?; waitedMs; limitMs; place?; repeat };Fields§
§subject: &'facts strWhat the lock protects, in words.
lock_directory: &'facts PathThe lock being waited for.
holder_pid: Option<i64>The live holder’s process, when its record can be read.
waited: DurationHow long the wait has lasted.
limit: DurationHow long the wait lasts before it gives up.
place: Option<QueuePlace>This commit’s place among the commits that queue for the same thing, when the registry knows it.
repeat: boolWhether an earlier notice of this wait already printed the hint.
Trait Implementations§
Source§impl<'facts> Clone for LockWaitFacts<'facts>
impl<'facts> Clone for LockWaitFacts<'facts>
impl<'facts> Copy for LockWaitFacts<'facts>
Auto Trait Implementations§
impl<'facts> Freeze for LockWaitFacts<'facts>
impl<'facts> RefUnwindSafe for LockWaitFacts<'facts>
impl<'facts> Send for LockWaitFacts<'facts>
impl<'facts> Sync for LockWaitFacts<'facts>
impl<'facts> Unpin for LockWaitFacts<'facts>
impl<'facts> UnsafeUnpin for LockWaitFacts<'facts>
impl<'facts> UnwindSafe for LockWaitFacts<'facts>
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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