Skip to main content

lost_for

Function lost_for 

Source
pub fn lost_for() -> Option<Duration>
Expand description

How long ago this process lost the checkout’s lease, when it did.

A superseded server keeps answering its sessions for the declared busy grace, so that a request in flight and the few that follow it finish where they started; after that every session is handed on (I2127).

// a process that never lost a lease has no such age
assert!(majordomus_cli::lease::lost_for().is_none() || majordomus_cli::lease::was_lost());