You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@orc.apache.org by GitBox <gi...@apache.org> on 2021/10/04 17:26:21 UTC

[GitHub] [orc] omalley commented on a change in pull request #924: ORC-1014. Add details when we get IOException from the file system

omalley commented on a change in pull request #924:
URL: https://github.com/apache/orc/pull/924#discussion_r721569492



##########
File path: java/core/src/java/org/apache/orc/impl/RecordReaderUtils.java
##########
@@ -414,7 +414,15 @@ static void readRanges(FSDataInputStream file,
     long offset = first.getOffset();
     int readSize = (int) (computeEnd(first, last) - offset);
     byte[] buffer = new byte[readSize];
-    file.readFully(offset, buffer, 0, buffer.length);
+    try {
+      file.readFully(offset, buffer, 0, buffer.length);
+    } catch(IOException e) {
+      throw new IOException(String.format("Failed while reading %s %d:%d",
+                                          file,

Review comment:
       Actually, especially on S3 it prints a bunch of other data, which is helpful. I haven't looked at DFSInputStream recently, does it just use the Object.toString?




-- 
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.

To unsubscribe, e-mail: dev-unsubscribe@orc.apache.org

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