hadoop-hdfs-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From c..@apache.org
Subject svn commit: r880971 - in /hadoop/hdfs/trunk: CHANGES.txt src/test/aop/org/apache/hadoop/hdfs/TestFiPipelines.java
Date Mon, 16 Nov 2009 21:38:37 GMT
Author: cos
Date: Mon Nov 16 21:38:37 2009
New Revision: 880971

URL: http://svn.apache.org/viewvc?rev=880971&view=rev
Log:
HDFS-774. Intermittent race condition in TestFiPipelines. Contributed by Konstantin Boudnik

Modified:
    hadoop/hdfs/trunk/CHANGES.txt
    hadoop/hdfs/trunk/src/test/aop/org/apache/hadoop/hdfs/TestFiPipelines.java

Modified: hadoop/hdfs/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/hadoop/hdfs/trunk/CHANGES.txt?rev=880971&r1=880970&r2=880971&view=diff
==============================================================================
--- hadoop/hdfs/trunk/CHANGES.txt (original)
+++ hadoop/hdfs/trunk/CHANGES.txt Mon Nov 16 21:38:37 2009
@@ -55,6 +55,8 @@
 
     HDFS-751. Fix TestCrcCorruption to pick up the correct datablocks to
     corrupt. (dhruba)
+    
+    HDFS-774. Intermittent race condition in TestFiPipelines (cos)
 
 Release 0.21.0 - Unreleased
 

Modified: hadoop/hdfs/trunk/src/test/aop/org/apache/hadoop/hdfs/TestFiPipelines.java
URL: http://svn.apache.org/viewvc/hadoop/hdfs/trunk/src/test/aop/org/apache/hadoop/hdfs/TestFiPipelines.java?rev=880971&r1=880970&r2=880971&view=diff
==============================================================================
--- hadoop/hdfs/trunk/src/test/aop/org/apache/hadoop/hdfs/TestFiPipelines.java (original)
+++ hadoop/hdfs/trunk/src/test/aop/org/apache/hadoop/hdfs/TestFiPipelines.java Mon Nov 16
21:38:37 2009
@@ -62,13 +62,10 @@
   }
 
   @After
-  public void shutDownCluster() throws IOException {
-    if (fs != null)
-      fs.close();
-    if (cluster != null)
-      cluster.shutdown();
+  synchronized public void shutDownCluster() throws IOException {
+    if (cluster != null) cluster.shutdown();
   }
-  
+
   /**
    * Test initiates and sets actions created by injection framework. The actions
    * work with both aspects of sending acknologment packets in a pipeline.
@@ -194,7 +191,8 @@
         // It has to be done like that, because local version of shutDownCluster()
         // won't work, because it tries to close an instance of FileSystem too.
         // Which is where the waiting is happening.
-        if (cluster !=null ) cluster.shutdown();
+        if (cluster !=null )
+          shutDownCluster();
       } catch (Exception e) {
         e.printStackTrace();
       }



Mime
View raw message