Selaa lähdekoodia

HDFS-7199. DFSOutputStream should not silently drop data if DataStreamer crashes with an unchecked exception (rushabhs via cmccabe)
(cherry picked from commit 56257fab1d5a7f66bebd9149c7df0436c0a57adb)
(cherry picked from commit 6f7ce842c015fedb30ec762caeb37a64e8258c4a)

Colin Patrick Mccabe 10 vuotta sitten
vanhempi
commit
8702cc2360

+ 3 - 0
hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt

@@ -890,6 +890,9 @@ Release 2.6.0 - UNRELEASED
 
     HDFS-7305. NPE seen in wbhdfs FS while running SLive. (jing9)
 
+    HDFS-7199. DFSOutputStream should not silently drop data if DataStreamer
+    crashes with an unchecked exception (rushabhs via cmccabe)
+
   BREAKDOWN OF HDFS-6584 ARCHIVAL STORAGE
 
     HDFS-6677. Change INodeFile and FSImage to support storage policy ID.

+ 2 - 0
hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/DFSOutputStream.java

@@ -692,6 +692,8 @@ public class DFSOutputStream extends FSOutputSummer
           }
           if (e instanceof IOException) {
             setLastException((IOException)e);
+          } else {
+            setLastException(new IOException("DataStreamer Exception: ",e));
           }
           hasError = true;
           if (errorIndex == -1 && restartingNodeIndex == -1) {