pub enum PushError {
Transport {
class: RetryClass,
},
InvalidResponse(String),
}Expand description
A failure that prevented the whole batch from being processed.
Per-notification refusals are not errors; they arrive as
PushDeliveryStatus::Rejected inside a successful result.
Variants§
Transport
The request never reached the provider, or the provider is failing.
Fields
§
class: RetryClassHow the caller should react, including any provider-requested delay.
InvalidResponse(String)
The provider answered with a body that does not match its contract.
Implementations§
Source§impl PushError
impl PushError
Sourcepub const fn is_retryable(&self) -> bool
pub const fn is_retryable(&self) -> bool
Returns whether sending the same batch again can succeed.
Sourcepub const fn retry_after(&self) -> Option<Duration>
pub const fn retry_after(&self) -> Option<Duration>
Returns the wait the provider asked for, if it named one.
Trait Implementations§
impl Eq for PushError
Source§impl Error for PushError
impl Error for PushError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Source§impl From<PushError> for ReceiptPollError
impl From<PushError> for ReceiptPollError
impl StructuralPartialEq for PushError
Auto Trait Implementations§
impl Freeze for PushError
impl RefUnwindSafe for PushError
impl Send for PushError
impl Sync for PushError
impl Unpin for PushError
impl UnsafeUnpin for PushError
impl UnwindSafe for PushError
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
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§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
Compare self to
key and return true if they are equal.