pub enum TaskRefusal {
Claimed,
NotOpen,
StaleClaim,
Closed,
SelfVerify,
NotSubmitted,
NotPermitted(PermitCheck),
OptinScope,
OptinChanged,
OptinInactive,
DailyBudget {
retry_after: Option<u64>,
},
StaleBase,
}Expand description
Why Cloud refused a task request (the reason of C0 1.9 §1).
Variants§
Claimed
Another claim holds the task.
NotOpen
A claim on a task that is not open.
StaleClaim
The lease id or fencing token is not the current claim’s.
Closed
A write to a done, rejected or cancelled task.
SelfVerify
C0 2.2 E48: the agent that did the work checked its own result.
NotSubmitted
C0 2.2 E48: a verdict on a task that is not submitted.
NotPermitted(PermitCheck)
The task’s role or the owner’s worker consent does not allow this agent.
OptinScope
The engine’s opt-in does not cover this vault or network (§4,
optin_scope).
OptinChanged
The claim named an older optin_id: read the opt-in again (§4,
optin_changed).
OptinInactive
No opt-in, or the owner stopped it: every claim of the engine ended
(§4, optin_inactive).
DailyBudget
The opt-in’s daily budget is used up until 00:00 UTC (§4,
daily_budget); never retried before retry_after.
StaleBase
C0 2.2 E47: a priority or labels write named an older
fields_version (stale_base): read the task again.
Implementations§
Source§impl TaskRefusal
impl TaskRefusal
Sourcepub fn ends_claim(self) -> bool
pub fn ends_claim(self) -> bool
Whether the claim this request acted under is gone for good (a stop of the opt-in ends every claim of the engine).
Trait Implementations§
Source§impl Clone for TaskRefusal
impl Clone for TaskRefusal
impl Copy for TaskRefusal
Source§impl Debug for TaskRefusal
impl Debug for TaskRefusal
Source§impl Display for TaskRefusal
impl Display for TaskRefusal
impl Eq for TaskRefusal
Source§impl PartialEq for TaskRefusal
impl PartialEq for TaskRefusal
impl StructuralPartialEq for TaskRefusal
Auto Trait Implementations§
impl Forget for TaskRefusal
impl Freeze for TaskRefusal
impl Move for TaskRefusal
impl RefUnwindSafe for TaskRefusal
impl Send for TaskRefusal
impl Sync for TaskRefusal
impl Unpin for TaskRefusal
impl UnsafeUnpin for TaskRefusal
impl UnwindSafe for TaskRefusal
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,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§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> ⓘ
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