pub struct Observation { /* private fields */ }Expand description
An exact durable owner record adopted after a successful outer transaction.
This records the owner, revision, and persisted duration observed together, plus the caller-clock instant at which that result was adopted. It is valid for takeover timing only while a later poll finds the same durable record.
Implementations§
Source§impl Observation
impl Observation
Sourcepub fn owner(&self) -> &ParticipantId
pub fn owner(&self) -> &ParticipantId
Returns the owner in the exact durable record this caller observed.
Sourcepub fn rank(&self) -> Rank
pub fn rank(&self) -> Rank
Returns the exact observed durable revision as a fencing rank.
A changed rank makes this observation ineligible to authorize a takeover, even if the owner text is unchanged.
Sourcepub fn lease_duration(&self) -> Duration
pub fn lease_duration(&self) -> Duration
Returns the lease duration persisted with the observed revision.
Followers use this value, rather than a handle’s configured duration, when deciding whether the unchanged record is old enough to challenge.
Sourcepub fn first_observed_at(&self) -> Duration
pub fn first_observed_at(&self) -> Duration
Returns the caller-clock time when this observation was adopted.
Compare it only with readings from the same caller’s monotonic clock. It is not a durable timestamp or a deadline for the observed owner.
Trait Implementations§
Source§impl Clone for Observation
impl Clone for Observation
Source§fn clone(&self) -> Observation
fn clone(&self) -> Observation
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more