Function s3_algo::s3_single_request

source ·
pub async fn s3_single_request<F, G, R>(
    future_factory: F,
    extra_initial_timeout_s: f64
) -> Result<(RequestReport, R), Error>
where F: Fn() -> G + Unpin + Clone + Send + Sync + 'static, G: Future<Output = Result<R, Error>> + Send,
Expand description

Issue a single S3 request, with retries and appropriate timeouts using sane defaults. Basically an easier, less general version of s3_request.

extra_initial_timeout: initial timeout of request (will increase with backoff) added to cfg.base_timeout. It can be set to 0 if the S3 operation is a small one, but if the operation size depends on for example a byte count or object count, set it to something that depends on that.