Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 2 additions & 4 deletions cloud/aws/aws_s3.cc
Original file line number Diff line number Diff line change
Expand Up @@ -305,13 +305,12 @@ class S3ReadableFile : public CloudStorageReadableFileImpl {
fname_.c_str(), offset, rangeLen);
return IOStatus::IOError("S3ReadableFile vsnprintf ", fname_.c_str());
}
Aws::String range(buffer);

// set up S3 request to read this range
Aws::S3::Model::GetObjectRequest request;
request.SetBucket(ToAwsString(bucket_));
request.SetKey(ToAwsString(fname_));
request.SetRange(range);
request.SetRange(Aws::String(buffer, ret));

Aws::S3::Model::GetObjectOutcome outcome =
s3client_->GetCloudObject(request);
Expand All @@ -332,7 +331,6 @@ class S3ReadableFile : public CloudStorageReadableFileImpl {
fname_.c_str(), offset, buffer, error.GetMessage().c_str());
return IOStatus::IOError(fname_, errmsg.c_str());
}
std::stringstream ss;
// const Aws::S3::Model::GetObjectResult& res = outcome.GetResult();

// extract data payload
Expand Down Expand Up @@ -688,7 +686,7 @@ IOStatus S3StorageProvider::ExistsCloudObject(const std::string& bucket_name,
IOStatus S3StorageProvider::GetCloudObjectSize(const std::string& bucket_name,
const std::string& object_path,
uint64_t* filesize) {
HeadObjectResult result;
HeadObjectResult result;
result.size = filesize;
return HeadObject(bucket_name, object_path, &result);
}
Expand Down