[][src]Struct tower::retry::Retry

pub struct Retry<P, S> { /* fields omitted */ }

Configure retrying requests of "failed" responses.

A Policy classifies what is a "failed" response.

Methods

impl<P, S> Retry<P, S>[src]

pub fn new(policy: P, service: S) -> Retry<P, S>[src]

Retry the inner service depending on this Policy.

Trait Implementations

impl<P, S> Clone for Retry<P, S> where
    P: Clone,
    S: Clone
[src]

impl<P, S> Unpin for Retry<P, S> where
    __UnpinStructRetry<P, S>: Unpin
[src]

impl<P, S, Request> Service<Request> for Retry<P, S> where
    P: Policy<Request, <S as Service<Request>>::Response, <S as Service<Request>>::Error> + Clone,
    S: Service<Request> + Clone
[src]

type Response = <S as Service<Request>>::Response

Responses given by the service.

type Error = <S as Service<Request>>::Error

Errors produced by the service.

type Future = ResponseFuture<P, S, Request>

The future response value.

impl<P, S> Debug for Retry<P, S> where
    P: Debug,
    S: Debug
[src]

Auto Trait Implementations

impl<P, S> Send for Retry<P, S> where
    P: Send,
    S: Send

impl<P, S> Sync for Retry<P, S> where
    P: Sync,
    S: Sync

impl<P, S> UnwindSafe for Retry<P, S> where
    P: UnwindSafe,
    S: UnwindSafe

impl<P, S> RefUnwindSafe for Retry<P, S> where
    P: RefUnwindSafe,
    S: RefUnwindSafe

Blanket Implementations

impl<T, Request> ServiceExt<Request> for T where
    T: Service<Request> + ?Sized
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> From<T> for T[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]