#[non_exhaustive]pub enum StepErrorKind {
#[non_exhaustive] ExecutionFailed,
#[non_exhaustive] SerializationFailed,
#[non_exhaustive] Interrupted,
}Expand description
Specific kinds of step failures.
Kinds classify; the escaping error is carried by StepError and
returned from its source().
§Examples
use aws_durable_execution_sdk::StepErrorKind;
fn body_failed(kind: &StepErrorKind) -> bool {
// Unit kind variants are `#[non_exhaustive]`: match them with
// `{ .. }` so a future field cannot break the pattern.
matches!(kind, StepErrorKind::ExecutionFailed { .. })
}Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
#[non_exhaustive]ExecutionFailed
The step body returned an error. A retry strategy receives this kind
for the body’s error, and the step returns it once the strategy
stops. The error’s source() is the body’s error.
#[non_exhaustive]SerializationFailed
A serialization or deserialization error occurred.
#[non_exhaustive]Interrupted
An AtMostOncePerRetry attempt started but recorded no outcome.
The SDK did not run the body again. It recorded the attempt as a
failure with error type StepInterruptedError and asked the retry
strategy whether to schedule another attempt.
Trait Implementations§
Source§impl Debug for StepErrorKind
impl Debug for StepErrorKind
Auto Trait Implementations§
impl Forget for StepErrorKind
impl Freeze for StepErrorKind
impl Move for StepErrorKind
impl RefUnwindSafe for StepErrorKind
impl Send for StepErrorKind
impl Sync for StepErrorKind
impl Unpin for StepErrorKind
impl UnsafeUnpin for StepErrorKind
impl UnwindSafe for StepErrorKind
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> 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> ⓘ
Converts
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> ⓘ
Converts
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 moreCreates a shared type from an unshared type.