pub struct RetryNode<N> {
pub inner: N,
pub policy: RetryPolicy,
}Expand description
Wrapper node that applies a RetryPolicy on inner node failures.
Internally it will re-run the inner node up to policy.max_attempts,
using backoff delays between attempts.
Fields§
§inner: NInner node to invoke.
policy: RetryPolicyPolicy controlling retry attempts and backoff.
Implementations§
Trait Implementations§
Source§impl<C, N> Node<C> for RetryNode<N>
impl<C, N> Node<C> for RetryNode<N>
Source§fn process<'life0, 'life1, 'async_trait>(
&'life0 self,
ctx: &'life1 C,
input: Self::Input,
) -> Pin<Box<dyn Future<Output = Result<Transition<Self::Output>, FloxideError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn process<'life0, 'life1, 'async_trait>(
&'life0 self,
ctx: &'life1 C,
input: Self::Input,
) -> Pin<Box<dyn Future<Output = Result<Transition<Self::Output>, FloxideError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Process an input value within the given context, producing a transition
Auto Trait Implementations§
impl<N> Freeze for RetryNode<N>where
N: Freeze,
impl<N> RefUnwindSafe for RetryNode<N>where
N: RefUnwindSafe,
impl<N> Send for RetryNode<N>where
N: Send,
impl<N> Sync for RetryNode<N>where
N: Sync,
impl<N> Unpin for RetryNode<N>where
N: Unpin,
impl<N> UnwindSafe for RetryNode<N>where
N: UnwindSafe,
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