Skip to content

Commit

Permalink
Try up to 100 times to upload, and update comment
Browse files Browse the repository at this point in the history
  • Loading branch information
Remoun Metyas committed May 3, 2022
1 parent 59a0993 commit e79fa89
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions ledger/distribution/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ impl S3BlockWriter {
let result: Result<PutObjectOutput, Error<RusotoError<PutObjectError>>> = retry(
delay::Exponential::from_millis(10)
.map(delay::jitter)
.take(10),
.take(100),
|| {
let req = PutObjectRequest {
bucket: path.to_string(),
Expand All @@ -135,7 +135,7 @@ impl S3BlockWriter {
},
);

// We should always succeed since retrying should never stop until that happens.
// Fail loudly if we cannot write to S3 after all the retries are up.
result.expect("failed to write to S3");
}
}
Expand Down

0 comments on commit e79fa89

Please sign in to comment.