liuml07 commented on a change in pull request #1761: HADOOP-16759. Filesystem openFile() builder to take a FileStatus param URL: https://github.com/apache/hadoop/pull/1761#discussion_r357794184
########## File path: hadoop-tools/hadoop-aws/src/main/java/org/apache/hadoop/fs/s3a/S3AFileSystem.java ########## @@ -955,23 +956,33 @@ protected URI canonicalizeUri(URI rawUri) { @Retries.RetryTranslated public FSDataInputStream open(Path f, int bufferSize) throws IOException { - return open(f, Optional.empty()); + return open(f, Optional.empty(), null); } /** * Opens an FSDataInputStream at the indicated Path. - * @param path the file to open + * if status contains an S3AFileStatus reference, it is used + * and so a HEAD request to the store is avoided. + * + * @param file the file to open * @param options configuration options if opened with the builder API. + * @param status optional file status. * @throws IOException IO failure. */ @Retries.RetryTranslated private FSDataInputStream open( - final Path path, - final Optional<Configuration> options) + final Path file, + final Optional<Configuration> options, + final S3AFileStatus status) Review comment: I'm not sure, but status can be Optional? ---------------------------------------------------------------- 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 With regards, Apache Git Services --------------------------------------------------------------------- To unsubscribe, e-mail: common-issues-unsubscr...@hadoop.apache.org For additional commands, e-mail: common-issues-h...@hadoop.apache.org