Skip to content

Commit

Permalink
chore(hil): Increase timeout for part download (#304)
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexKaravaev authored Dec 2, 2024
1 parent ff235d3 commit d756733
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion hil/src/download_s3.rs
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ use tracing::{info, warn};
const PART_SIZE: u64 = 25 * 1024 * 1024; // 25 MiB
const CONCURRENCY: usize = 16;
const TIMEOUT_RETRY_ATTEMPTS: u32 = 5;
const PART_DOWNLOAD_TIMEOUT_SECS: u64 = 120;

#[derive(Debug, Clone, Copy, PartialEq, Eq)]
pub enum ExistingFileBehavior {
Expand Down Expand Up @@ -242,7 +243,7 @@ async fn download_part_retry_on_timeout(
) -> Result<bytes::Bytes> {
loop {
match timeout(
Duration::from_secs(30), // Timeout for downloading one part
Duration::from_secs(PART_DOWNLOAD_TIMEOUT_SECS), // Timeout for downloading one part
download_part(range, client, bucket, key),
)
.await
Expand Down

0 comments on commit d756733

Please sign in to comment.