struct RecoveryCounters {
useful_shares: AtomicU64,
shares_seen: AtomicU64,
recovered_polynomials: AtomicU32,
invalid_shares: AtomicU64,
target_useful_shares: u64,
}Expand description
Progress counters whose lifetime can outlast the reconstruction buffers that produced them.
Full recovery releases the accumulator and every polynomial builder immediately, but shares are bound into SURBs before that point and can still be waiting in the Exit’s FIFO buffer. Keeping only these counters lets those already-paid shares report liveness without retaining any secret reconstruction material.
Fields§
§recovered_polynomials: AtomicU32Implementations§
Source§impl RecoveryCounters
impl RecoveryCounters
fn new(target_useful_shares: u64) -> Self
fn record_completed_part(&self)
fn snapshot<P>(&self, ssa_id: SsaId<P>) -> SsaRecoveryProgress<P>
Auto Trait Implementations§
impl !Freeze for RecoveryCounters
impl RefUnwindSafe for RecoveryCounters
impl Send for RecoveryCounters
impl Sync for RecoveryCounters
impl Unpin for RecoveryCounters
impl UnsafeUnpin for RecoveryCounters
impl UnwindSafe for RecoveryCounters
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
§impl<T> FutureExt for T
impl<T> FutureExt for T
§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§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