HDFS-12378.  TestClientProtocolForPipelineRecovery#testZeroByteBlockRecovery 
fails on trunk. (Lei (Eddy) Xu)


Project: http://git-wip-us.apache.org/repos/asf/hadoop/repo
Commit: http://git-wip-us.apache.org/repos/asf/hadoop/commit/61cee3a0
Tree: http://git-wip-us.apache.org/repos/asf/hadoop/tree/61cee3a0
Diff: http://git-wip-us.apache.org/repos/asf/hadoop/diff/61cee3a0

Branch: refs/heads/YARN-1011
Commit: 61cee3a0b9a8ea2e4f6257c17c2d90c7c930cc34
Parents: 390c2b5
Author: Lei Xu <l...@apache.org>
Authored: Thu Sep 14 17:02:48 2017 -0700
Committer: Lei Xu <l...@apache.org>
Committed: Thu Sep 14 17:03:25 2017 -0700

----------------------------------------------------------------------
 .../apache/hadoop/hdfs/server/datanode/DataNode.java    | 12 ++++++++++--
 1 file changed, 10 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hadoop/blob/61cee3a0/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/DataNode.java
----------------------------------------------------------------------
diff --git 
a/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/DataNode.java
 
b/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/DataNode.java
index 837ac07..042a627 100644
--- 
a/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/DataNode.java
+++ 
b/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/DataNode.java
@@ -3000,8 +3000,16 @@ public class DataNode extends ReconfigurableBase
     b.setNumBytes(visible);
 
     if (targets.length > 0) {
-      new Daemon(new DataTransfer(targets, targetStorageTypes,
-          targetStorageIds, b, stage, client)).start();
+      Daemon daemon = new Daemon(threadGroup,
+          new DataTransfer(targets, targetStorageTypes, targetStorageIds, b,
+              stage, client));
+      daemon.start();
+      try {
+        daemon.join();
+      } catch (InterruptedException e) {
+        throw new IOException(
+            "Pipeline recovery for " + b + " is interrupted.", e);
+      }
     }
   }
 


---------------------------------------------------------------------
To unsubscribe, e-mail: common-commits-unsubscr...@hadoop.apache.org
For additional commands, e-mail: common-commits-h...@hadoop.apache.org

Reply via email to