Set factor of current backoff.
This function will panic if the input factor is smaller than 1.0
.
Set jitter of current backoff.
If jitter is enabled, ExponentialBackoff will add a random jitter in [0, min_delay)
to current delay.
Set max_delay of current backoff.
Delay will not increase if the current delay is larger than max_delay.
Set max_times of current backoff.
Backoff will return None
if max times are reached.
Copyright © 2022-2024, The Apache Software Foundation. Apache OpenDAL, OpenDAL, and Apache are either registered trademarks or trademarks of the Apache Software Foundation.
Retry layer
Add retry for temporary failed operations.
Notes
This layer will retry failed operations when [
Error::is_temporary
] returns true. If the operation still failed, this layer will set error toPersistent
which means error has been retried.write
andblocking_write
don't support retry so far, visit this issue for more details.Examples