pub enum RetryEffect {
Pass,
CoolingDown {
until: SystemTime,
},
Failed,
NotSyncing,
}Expand description
What the person’s retry would do if made now (E5), as
coven_retry_effect holds it: run a pass, or be answered at once
without one. An app offers a retry only while it is Pass; the status
says why it is not.
Variants§
Pass
A pass runs for the retry, and its end answers it.
CoolingDown
A provider cooldown holds every pass until then, by the store’s
clock: the retry is answered CoolingDown at once, and the pass runs
once the cooldown ends.
Fields
until: SystemTimeWhen the cooldown ends, by the store’s clock.
Failed
A failure only new credentials, an update or a reset can clear holds
every pass: the retry is answered Failed with it at once. The
status shows the failure.
NotSyncing
Sync is stopped or the handle closed: the retry is answered
NotSyncing at once.
Implementations§
Source§impl RetryEffect
impl RetryEffect
Sourcepub fn read(sql: SqlReadContext<'_>) -> Result<RetryEffect, DbError>
pub fn read(sql: SqlReadContext<'_>) -> Result<RetryEffect, DbError>
Read coven_retry_effect, as an app’s live query does:
handle.subscribe(RetryEffect::read).
Sourcepub fn from_columns(
effect: &str,
cooling_until: Option<i64>,
) -> Result<RetryEffect, DbError>
pub fn from_columns( effect: &str, cooling_until: Option<i64>, ) -> Result<RetryEffect, DbError>
The effect that coven_retry_effect’s effect and cooling_until
columns name, for an app that reads them in a query of its own. A
pair the view never computes is an invariant error.
Sourcepub fn follow(database: &StoreDatabase) -> Followed<RetryEffect, DbError>
pub fn follow(database: &StoreDatabase) -> Followed<RetryEffect, DbError>
Follow coven_retry_effect with a live query, as an app does.
Trait Implementations§
Source§impl Clone for RetryEffect
impl Clone for RetryEffect
Source§fn clone(&self) -> RetryEffect
fn clone(&self) -> RetryEffect
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreimpl Copy for RetryEffect
Source§impl Debug for RetryEffect
impl Debug for RetryEffect
impl Eq for RetryEffect
Source§impl From<RetryState> for RetryEffect
impl From<RetryState> for RetryEffect
Source§fn from(state: RetryState) -> RetryEffect
fn from(state: RetryState) -> RetryEffect
A held failure answers before a cooldown: the cooldown’s end would
not let the pass run. coven_retry_effect.effect is computed alike.
Source§impl PartialEq for RetryEffect
impl PartialEq for RetryEffect
impl StructuralPartialEq for RetryEffect
Auto Trait Implementations§
impl Freeze for RetryEffect
impl RefUnwindSafe for RetryEffect
impl Send for RetryEffect
impl Sync for RetryEffect
impl Unpin for RetryEffect
impl UnsafeUnpin for RetryEffect
impl UnwindSafe for RetryEffect
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.impl<T> ErasedDestructor for Twhere
T: 'static,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> 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> ⓘ
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> ⓘ
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