[
https://issues.apache.org/jira/browse/HADOOP-19795?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18070516#comment-18070516
]
ASF GitHub Bot commented on HADOOP-19795:
-----------------------------------------
manika137 commented on code in PR #8212:
URL: https://github.com/apache/hadoop/pull/8212#discussion_r3026470275
##########
hadoop-tools/hadoop-azure/src/main/java/org/apache/hadoop/fs/azurebfs/services/AbfsInputStream.java:
##########
@@ -561,11 +574,60 @@ protected int readInternal(final long position, final
byte[] b, final int offset
}
}
+ /**
+ * Creates an exception indicating that a read operation was attempted on a
directory.
+ *
+ * @return an {@link AbfsRestOperationException} indicating the operation is
not permitted on a directory
+ */
+ private IOException directoryReadException() {
Review Comment:
Taken
##########
hadoop-tools/hadoop-azure/src/main/java/org/apache/hadoop/fs/azurebfs/services/AbfsAdaptiveInputStream.java:
##########
@@ -83,7 +83,14 @@ protected int readOneBlock(final byte[] b, final int off,
final int len) throws
// Reset Read Type back to normal and set again based on code flow.
getTracingContext().setReadType(ReadType.NORMAL_READ);
- if (shouldAlwaysReadBufferSize()) {
+
+ // If restrictGpsOnOpenFile config is enabled, skip prefetch for the
first read since contentLength
+ // is not available yet to determine prefetch block size.
Review Comment:
Modified the comment
> ABFS: GetPathStatus Optimization on OpenFileForRead
> ---------------------------------------------------
>
> Key: HADOOP-19795
> URL: https://issues.apache.org/jira/browse/HADOOP-19795
> Project: Hadoop Common
> Issue Type: Task
> Components: fs/azure
> Affects Versions: 3.4.1, 3.4.2
> Reporter: Manika Joshi
> Assignee: Manika Joshi
> Priority: Major
> Labels: pull-request-available
>
> We do a getPathStatus call during file open for read. This call is primarily
> used to fetch the file’s metadata properties before the actual read begins.
> We are now introducing an optional, config-driven read flow that avoids the
> getPathStatus call during open and instead derives required metadata from the
> read response itself.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]