pub enum HiveError {
Show 24 variants
Offline(String),
NotConnected,
Unauthorized,
PlanRequired(Box<PlanNeed>),
InstanceLimit {
limit: Option<u64>,
used: Option<u64>,
},
QuotaExceeded(Box<Quota>),
PolicyDenied(PolicyDenial),
LeaseLapsed,
Revoked(Revocation),
Forbidden,
Vetoed,
UploadDisabled(HiveUploadKind),
NotFound,
Conflict {
expected: Option<u64>,
actual: Option<u64>,
},
ScreeningBlocked,
UpgradeRequired {
min: Option<String>,
},
RateLimited {
retry_after: Option<u64>,
},
DeviceFlow(String),
Protocol(String),
Config(String),
Local(String),
Refused(String),
Task {
refusal: TaskRefusal,
number: Option<u64>,
detail: Option<String>,
},
Server {
status: u16,
code: String,
},
}Variants§
Offline(String)
Hive could not be reached (DNS, connect, TLS, timeout, reset).
NotConnected
The instance is not enrolled on this machine.
The service refused the instance’s credentials.
PlanRequired(Box<PlanNeed>)
402 plan_required: the plan lacks a feature (C0 2.x names it), or,
from a 1.x Hive that names none, Hive itself (an engine seat).
InstanceLimit
Every instance seat of the organization is taken.
QuotaExceeded(Box<Quota>)
A Release B quota is used up (409/429 quota_exceeded, Hive API
§8.1). Nothing is charged; monthly quotas are waited out (the outbox
keeps local work), counted ones need a person.
PolicyDenied(PolicyDenial)
Hive’ own enforcement of a policy member refused (403 policy_denied, API §7.2). Never retried until the policy changes.
LeaseLapsed
The lease is past grace_until; reconnect.
Revoked(Revocation)
A workspace admin revoked this instance (401 instance_revoked, C0
2.0 E12). Recorded locally; no Hive call is made until a new
connect (fail closed, never retried).
Forbidden
The lease lacks the right this request needs.
Vetoed
An organization veto bars this lease or handoff (forbidden_right,
reason: vetoed; C5c). Never retried until the veto is lifted.
UploadDisabled(HiveUploadKind)
The organization switched this upload off; stop it and drop its queue until a lease allows it again (never retried).
NotFound
Conflict
ScreeningBlocked
UpgradeRequired
RateLimited
DeviceFlow(String)
The device flow ended without approval.
Protocol(String)
A response or stored artifact broke the contract (bad signature, wrong shape, unknown key).
Config(String)
Configuration that cannot work (URL scheme, root key).
Local(String)
Local storage failed.
Refused(String)
A local rule refused the request before it left (worker gate, outgoing screening); the message carries no content.
Task
Hive refused a task request (C0 1.9 §1); number names the task.
Fields
refusal: TaskRefusalServer
Any other service answer.
Implementations§
Trait Implementations§
impl Eq for HiveError
Source§impl Error for HiveError
impl Error for HiveError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()
Source§impl From<ConsentError> for HiveError
impl From<ConsentError> for HiveError
Source§fn from(error: ConsentError) -> Self
fn from(error: ConsentError) -> Self
Source§impl From<Refusal> for HiveError
A refusal reaches the caller with its own (content-free) words.
impl From<Refusal> for HiveError
A refusal reaches the caller with its own (content-free) words.
impl StructuralPartialEq for HiveError
Auto Trait Implementations§
impl Freeze for HiveError
impl RefUnwindSafe for HiveError
impl Send for HiveError
impl Sync for HiveError
impl Unpin for HiveError
impl UnsafeUnpin for HiveError
impl UnwindSafe for HiveError
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§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
impl<A, B, T> HttpServerConnExec<A, B> for Twhere
B: Body,
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