Skip to main content

RewardProverStatus

Struct RewardProverStatus 

Source
pub struct RewardProverStatus {
Show 13 fields pub launcher_id: HexId, pub store_id: HexId, pub root: HexId, pub prover_state: ProverState, pub prover_state_since: u64, pub last_cycle_started_at: Option<u64>, pub last_cycle_completed_at: Option<u64>, pub next_cycle_due_at: Option<u64>, pub last_entry_write_at: Option<u64>, pub consecutive_cycle_failures: u32, pub pending_entry_writes: u32, pub observed_at: u64, pub counters: ProverCounters,
}
Expand description

One distributor’s prover-loop status — SPEC §2.3 / §2.4.

§No health boolean, no pre-computed staleness

This type carries no healthy/ok/up/running/stale field and no seconds_since_last_run. SPEC §2.4: a wedged loop cannot report its own wedging — a boolean the writer sets on every successful cycle reads true forever after exactly the failure it exists to reveal, because the write that would flip it never runs. The reader derives staleness itself from last_cycle_completed_at / next_cycle_due_at against observed_at and its own clock. Contrast GetRewardDistributorResult::entry_set_stale, which IS a boolean — it is permitted there because it is computed from the singleton’s on-chain spend history by the responder at read time, not self-reported by the writer this type describes.

Fields§

§launcher_id: HexId

The distributor singleton’s launcher id (64-hex).

§store_id: HexId

The backing store’s launcher id (64-hex).

§root: HexId

The store’s current generation root (64-hex).

§prover_state: ProverState

The loop’s current state.

§prover_state_since: u64

Unix seconds the loop entered prover_state.

§last_cycle_started_at: Option<u64>

Unix seconds the current/most recent cycle started, if any has run.

§last_cycle_completed_at: Option<u64>

Unix seconds the most recent cycle completed, if any has completed.

§next_cycle_due_at: Option<u64>

Unix seconds the next cycle is scheduled, if the loop is scheduling one.

§last_entry_write_at: Option<u64>

Unix seconds of the most recent entry-set write, if any.

§consecutive_cycle_failures: u32

Consecutive cycle failures (resets to 0 on a completed cycle).

§pending_entry_writes: u32

Entry writes queued but not yet committed.

§observed_at: u64

Unix seconds this status was assembled (the reader’s staleness anchor).

§counters: ProverCounters

The loop’s running counters.

Trait Implementations§

Source§

impl Clone for RewardProverStatus

Source§

fn clone(&self) -> RewardProverStatus

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for RewardProverStatus

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<'de> Deserialize<'de> for RewardProverStatus

Source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
Source§

impl Eq for RewardProverStatus

Source§

impl PartialEq for RewardProverStatus

Source§

fn eq(&self, other: &RewardProverStatus) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more
Source§

impl Serialize for RewardProverStatus

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
Source§

impl StructuralPartialEq for RewardProverStatus

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.