aboutsummaryrefslogtreecommitdiff
path: root/src/api/s3/multipart.rs
diff options
context:
space:
mode:
authorAlex <alex@adnab.me>2024-02-26 17:52:45 +0000
committerAlex <alex@adnab.me>2024-02-26 17:52:45 +0000
commit911a83ea7d06143c5a9621f88020ab6c0850ba54 (patch)
tree26caedf5ef22e6b299d1e2921d7ef854d5d132d6 /src/api/s3/multipart.rs
parent17b55205aa666e78b73d93754574aca83a12193a (diff)
parentb76c0c102ee07758ecf8ae4dfeef0a9a095c4136 (diff)
downloadgarage-911a83ea7d06143c5a9621f88020ab6c0850ba54.tar.gz
garage-911a83ea7d06143c5a9621f88020ab6c0850ba54.zip
Merge pull request 'rewrite read_and_put_block as a series of steps with channels' (#734) from refactor-put into main
Reviewed-on: https://git.deuxfleurs.fr/Deuxfleurs/garage/pulls/734
Diffstat (limited to 'src/api/s3/multipart.rs')
-rw-r--r--src/api/s3/multipart.rs14
1 files changed, 2 insertions, 12 deletions
diff --git a/src/api/s3/multipart.rs b/src/api/s3/multipart.rs
index b9d15b21..5959bcd6 100644
--- a/src/api/s3/multipart.rs
+++ b/src/api/s3/multipart.rs
@@ -6,7 +6,6 @@ use hyper::{Request, Response};
use md5::{Digest as Md5Digest, Md5};
use garage_table::*;
-use garage_util::async_hash::*;
use garage_util::data::*;
use garage_model::bucket_table::Bucket;
@@ -135,17 +134,8 @@ pub async fn handle_put_part(
garage.version_table.insert(&version).await?;
// Copy data to version
- let first_block_hash = async_blake2sum(first_block.clone()).await;
-
- let (total_size, data_md5sum, data_sha256sum) = read_and_put_blocks(
- &garage,
- &version,
- part_number,
- first_block,
- first_block_hash,
- &mut chunker,
- )
- .await?;
+ let (total_size, data_md5sum, data_sha256sum, _) =
+ read_and_put_blocks(&garage, &version, part_number, first_block, &mut chunker).await?;
// Verify that checksums map
ensure_checksum_matches(