chore: cleanup error handling

This commit is contained in:
Matteo Settenvini 2025-08-10 18:01:44 +02:00
parent 3c07716a83
commit caacb91123
Signed by: matteo
GPG key ID: 1C1B12600D81DE05
2 changed files with 28 additions and 21 deletions

View file

@ -2,9 +2,10 @@
// SPDX-License-Identifier: EUPL-1.2
use {
object_store::{ObjectStore, aws},
object_store::{BackoffConfig, ObjectStore, RetryConfig, aws},
rocket::serde::Deserialize,
serde::de::Error,
std::time::Duration,
};
#[derive(Deserialize)]
@ -48,6 +49,11 @@ impl TryInto<Box<dyn ObjectStore>> for S3Config {
.with_secret_access_key(self.secret_access_key)
.with_virtual_hosted_style_request(!self.path_style)
.with_allow_http(true)
.with_retry(RetryConfig {
max_retries: 1,
backoff: BackoffConfig::default(),
retry_timeout: Duration::from_millis(500),
})
.build()?;
log::info!(