pub struct ActivityFailureError { /* private fields */ }Expand description
A normalized activity failure wrapper.
Implementations§
Source§impl ActivityFailureError
impl ActivityFailureError
Sourcepub fn activity_id(&self) -> &str
pub fn activity_id(&self) -> &str
Returns the activity id reported by the failure.
Sourcepub fn activity_type(&self) -> Option<&ActivityType>
pub fn activity_type(&self) -> Option<&ActivityType>
Returns the activity type, if present.
Sourcepub fn scheduled_event_id(&self) -> i64
pub fn scheduled_event_id(&self) -> i64
Returns the scheduled event id.
Sourcepub fn started_event_id(&self) -> i64
pub fn started_event_id(&self) -> i64
Returns the started event id.
Sourcepub fn retry_state(&self) -> RetryState
pub fn retry_state(&self) -> RetryState
Returns the retry state reported by core.
Sourcepub fn as_timeout(&self) -> Option<&TimeoutError>
pub fn as_timeout(&self) -> Option<&TimeoutError>
If this ActivityFailureError was caused by a timeout, returns the associated
TimeoutError.
Sourcepub fn as_cancelled(&self) -> Option<&CancelledError>
pub fn as_cancelled(&self) -> Option<&CancelledError>
If this ActivityFailureError was caused by a cancellation, returns the associated
CancelledError.
Source§impl ActivityFailureError
impl ActivityFailureError
Sourcepub fn cause(&self) -> Option<&IncomingError>
pub fn cause(&self) -> Option<&IncomingError>
Returns the normalized cause, if any.
Sourcepub fn into_failure(self) -> Failure
pub fn into_failure(self) -> Failure
Consumes this wrapper and returns the retained proto failure.
Sourcepub fn into_parts(self) -> (Failure, Option<IncomingError>)
pub fn into_parts(self) -> (Failure, Option<IncomingError>)
Consumes this wrapper and returns the retained proto failure and normalized cause.
Trait Implementations§
Source§impl Debug for ActivityFailureError
impl Debug for ActivityFailureError
Source§impl Display for ActivityFailureError
impl Display for ActivityFailureError
Source§impl Error for ActivityFailureError
impl Error for ActivityFailureError
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()
Auto Trait Implementations§
impl Freeze for ActivityFailureError
impl !RefUnwindSafe for ActivityFailureError
impl Send for ActivityFailureError
impl Sync for ActivityFailureError
impl Unpin for ActivityFailureError
impl UnsafeUnpin for ActivityFailureError
impl !UnwindSafe for ActivityFailureError
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> 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> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T in a tonic::Request