pub async fn retry_with_backoff<F, T, E>(
operation: F,
max_retries: u32,
operation_name: &str,
) -> Result<T, E>Expand description
Retry an async operation with exponential backoff.
Attempts the operation up to max_retries times with exponential backoff
between attempts.
§Type Parameters
F- Future-producing functionT- Success result typeE- Error type (must implement Display)
§Errors
Returns the last error if all retry attempts fail.