pub struct HttpRateLimitRetryPolicy;
Expand description
Implements RetryPolicy that will retry requests that errored with status code 429 i.e. TOO_MANY_REQUESTS
Infura often fails with a "header not found"
rpc error which is apparently linked to load
balancing, which are retried as well.
Trait Implementations§
source§impl Debug for HttpRateLimitRetryPolicy
impl Debug for HttpRateLimitRetryPolicy
source§impl Default for HttpRateLimitRetryPolicy
impl Default for HttpRateLimitRetryPolicy
source§fn default() -> HttpRateLimitRetryPolicy
fn default() -> HttpRateLimitRetryPolicy
Returns the “default value” for a type. Read more
source§impl RetryPolicy<ClientError> for HttpRateLimitRetryPolicy
impl RetryPolicy<ClientError> for HttpRateLimitRetryPolicy
source§fn should_retry(&self, error: &ClientError) -> bool
fn should_retry(&self, error: &ClientError) -> bool
Whether to retry the request based on the given
error
source§fn backoff_hint(&self, error: &ClientError) -> Option<Duration>
fn backoff_hint(&self, error: &ClientError) -> Option<Duration>
Providers may include the
backoff
in the error response directlyAuto Trait Implementations§
impl RefUnwindSafe for HttpRateLimitRetryPolicy
impl Send for HttpRateLimitRetryPolicy
impl Sync for HttpRateLimitRetryPolicy
impl Unpin for HttpRateLimitRetryPolicy
impl UnwindSafe for HttpRateLimitRetryPolicy
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