[GitHub] [arrow] rdettai commented on a change in pull request #7547: ARROW-8950: [C++] Avoid HEAD when possible in S3 filesystem

2020-06-26 Thread GitBox


rdettai commented on a change in pull request #7547:
URL: https://github.com/apache/arrow/pull/7547#discussion_r446015106



##
File path: cpp/src/arrow/filesystem/s3fs.cc
##
@@ -397,9 +399,17 @@ class ObjectInputFile : public io::RandomAccessFile {
   ObjectInputFile(Aws::S3::S3Client* client, const S3Path& path)
   : client_(client), path_(path) {}
 
+  ObjectInputFile(Aws::S3::S3Client* client, const S3Path& path, int64_t size)
+  : client_(client), path_(path), content_length_(size) {}
+
   Status Init() {
 // Issue a HEAD Object to get the content-length and ensure any
 // errors (e.g. file not found) don't wait until the first Read() call.

Review comment:
   This comment got a little bit out of sync with the code below ;-)





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [arrow] rdettai commented on a change in pull request #7547: ARROW-8950: [C++] Avoid HEAD when possible in S3 filesystem

2020-06-26 Thread GitBox


rdettai commented on a change in pull request #7547:
URL: https://github.com/apache/arrow/pull/7547#discussion_r446015106



##
File path: cpp/src/arrow/filesystem/s3fs.cc
##
@@ -397,9 +399,17 @@ class ObjectInputFile : public io::RandomAccessFile {
   ObjectInputFile(Aws::S3::S3Client* client, const S3Path& path)
   : client_(client), path_(path) {}
 
+  ObjectInputFile(Aws::S3::S3Client* client, const S3Path& path, int64_t size)
+  : client_(client), path_(path), content_length_(size) {}
+
   Status Init() {
 // Issue a HEAD Object to get the content-length and ensure any
 // errors (e.g. file not found) don't wait until the first Read() call.

Review comment:
   This comments got a little bit out of sync with the code below ;-)





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org