sahilTakiar commented on a change in pull request #963: HDFS-14564: Add libhdfs
APIs for readFully; add readFully to ByteBufferPositionedReadable
URL: https://github.com/apache/hadoop/pull/963#discussion_r323503154
##########
File path:
hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/ByteBufferPositionedReadable.java
##########
@@ -55,6 +56,10 @@
* <p>
* Implementations should treat 0-length requests as legitimate, and must not
* signal an error upon their receipt.
+ * <p>
+ * This does not change the current offset of a file, and is thread-safe.
+ *
+ * <i>Warning: Not all filesystems satisfy the thread-safety requirement.</i>
Review comment:
I originally copied this from `PositionedReadable`, but after taking a
second look, the only two filesystems that implement this interface are
`CryptoInputStream` and `DFSInputStream` and both of their implementations are
thread safe. So I removed this.
----------------------------------------------------------------
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:
[email protected]
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]