Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F3302284
D4649.id15002.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1 KB
Referenced Files
None
Subscribers
None
D4649.id15002.diff
View Options
diff --git a/services/blob/src/Reactors/server/GetReactor.h b/services/blob/src/Reactors/server/GetReactor.h
--- a/services/blob/src/Reactors/server/GetReactor.h
+++ b/services/blob/src/Reactors/server/GetReactor.h
@@ -63,21 +63,20 @@
void initialize() override {
this->s3Path = tools::findS3Path(this->request.holder());
- this->fileSize =
- getBucket(s3Path.getBucketName()).getObjectSize(s3Path.getObjectName());
-
- this->getRequest.SetBucket(this->s3Path.getBucketName());
- this->getRequest.SetKey(this->s3Path.getObjectName());
AwsS3Bucket bucket = getBucket(this->s3Path.getBucketName());
if (!bucket.isAvailable()) {
throw std::runtime_error(
"bucket [" + this->s3Path.getBucketName() + "] not available");
}
- const size_t fileSize = bucket.getObjectSize(this->s3Path.getObjectName());
+
+ this->fileSize = bucket.getObjectSize(this->s3Path.getObjectName());
if (this->fileSize == 0) {
throw std::runtime_error("object empty");
}
+
+ this->getRequest.SetBucket(this->s3Path.getBucketName());
+ this->getRequest.SetKey(this->s3Path.getObjectName());
};
void doneCallback() override{};
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Tue, Nov 19, 6:50 AM (22 h, 30 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2536763
Default Alt Text
D4649.id15002.diff (1 KB)
Attached To
Mode
D4649: [services] Blob - Get Reactor - Fix initialize logic
Attached
Detach File
Event Timeline
Log In to Comment