hadoop-common-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cutt...@apache.org
Subject svn commit: r440864 - in /lucene/hadoop/trunk: ./ src/java/org/apache/hadoop/ipc/ src/java/org/apache/hadoop/mapred/ src/test/org/apache/hadoop/dfs/
Date Wed, 06 Sep 2006 20:50:12 GMT
Author: cutting
Date: Wed Sep  6 13:50:11 2006
New Revision: 440864

URL: http://svn.apache.org/viewvc?view=rev&rev=440864
Log:
HADOOP-408.  Adjust some timeouts and remove some others so that unit tests run faster.

Modified:
    lucene/hadoop/trunk/CHANGES.txt
    lucene/hadoop/trunk/src/java/org/apache/hadoop/ipc/Client.java
    lucene/hadoop/trunk/src/java/org/apache/hadoop/ipc/RPC.java
    lucene/hadoop/trunk/src/java/org/apache/hadoop/ipc/Server.java
    lucene/hadoop/trunk/src/java/org/apache/hadoop/mapred/TaskTracker.java
    lucene/hadoop/trunk/src/test/org/apache/hadoop/dfs/MiniDFSCluster.java

Modified: lucene/hadoop/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/lucene/hadoop/trunk/CHANGES.txt?view=diff&rev=440864&r1=440863&r2=440864
==============================================================================
--- lucene/hadoop/trunk/CHANGES.txt (original)
+++ lucene/hadoop/trunk/CHANGES.txt Wed Sep  6 13:50:11 2006
@@ -123,6 +123,9 @@
 30. HADOOP-424.  Fix MapReduce so that jobs which generate zero splits
     do not fail.  (Frédéric Bertin via cutting)
 
+31. HADOOP-408.  Adjust some timeouts and remove some others so that
+    unit tests run faster.  (cutting)
+
 
 Release 0.5.0 - 2006-08-04
 

Modified: lucene/hadoop/trunk/src/java/org/apache/hadoop/ipc/Client.java
URL: http://svn.apache.org/viewvc/lucene/hadoop/trunk/src/java/org/apache/hadoop/ipc/Client.java?view=diff&rev=440864&r1=440863&r2=440864
==============================================================================
--- lucene/hadoop/trunk/src/java/org/apache/hadoop/ipc/Client.java (original)
+++ lucene/hadoop/trunk/src/java/org/apache/hadoop/ipc/Client.java Wed Sep  6 13:50:11 2006
@@ -280,9 +280,6 @@
    * using this client. */
   public void stop() {
     LOG.info("Stopping client");
-    try {
-      Thread.sleep(timeout);                        // let all calls complete
-    } catch (InterruptedException e) {}
     running = false;
   }
 

Modified: lucene/hadoop/trunk/src/java/org/apache/hadoop/ipc/RPC.java
URL: http://svn.apache.org/viewvc/lucene/hadoop/trunk/src/java/org/apache/hadoop/ipc/RPC.java?view=diff&rev=440864&r1=440863&r2=440864
==============================================================================
--- lucene/hadoop/trunk/src/java/org/apache/hadoop/ipc/RPC.java (original)
+++ lucene/hadoop/trunk/src/java/org/apache/hadoop/ipc/RPC.java Wed Sep  6 13:50:11 2006
@@ -229,7 +229,7 @@
         LOG.info("Problem connecting to server: " + addr);
       }
       try {
-        Thread.sleep(10*1000);
+        Thread.sleep(1000);
       } catch (InterruptedException ie) {
         // IGNORE
       }

Modified: lucene/hadoop/trunk/src/java/org/apache/hadoop/ipc/Server.java
URL: http://svn.apache.org/viewvc/lucene/hadoop/trunk/src/java/org/apache/hadoop/ipc/Server.java?view=diff&rev=440864&r1=440863&r2=440864
==============================================================================
--- lucene/hadoop/trunk/src/java/org/apache/hadoop/ipc/Server.java (original)
+++ lucene/hadoop/trunk/src/java/org/apache/hadoop/ipc/Server.java Wed Sep  6 13:50:11 2006
@@ -541,16 +541,11 @@
     }
   }
 
-  /** Stops the service.  No new calls will be handled after this is called.  All
-   * subthreads will likely be finished after this returns.
-   */
+  /** Stops the service.  No new calls will be handled after this is called. */
   public synchronized void stop() {
     LOG.info("Stopping server on " + port);
     running = false;
     listener.doStop();
-    try {
-      Thread.sleep(timeout);     //  inexactly wait for pending requests to finish
-    } catch (InterruptedException e) {}
     notifyAll();
   }
 

Modified: lucene/hadoop/trunk/src/java/org/apache/hadoop/mapred/TaskTracker.java
URL: http://svn.apache.org/viewvc/lucene/hadoop/trunk/src/java/org/apache/hadoop/mapred/TaskTracker.java?view=diff&rev=440864&r1=440863&r2=440864
==============================================================================
--- lucene/hadoop/trunk/src/java/org/apache/hadoop/mapred/TaskTracker.java (original)
+++ lucene/hadoop/trunk/src/java/org/apache/hadoop/mapred/TaskTracker.java Wed Sep  6 13:50:11
2006
@@ -59,7 +59,6 @@
     int taskReportPort;
 
     Server taskReportServer = null;
-    Server mapOutputServer = null;
     InterTrackerProtocol jobClient;
 
     StatusHttpServer server = null;
@@ -209,7 +208,7 @@
           close();
           if (this.server != null) {
             try {
-                LOG.info("Shttting down StatusHttpServer");
+                LOG.info("Shutting down StatusHttpServer");
                 this.server.stop();
             } catch (InterruptedException ex) {
                 ex.printStackTrace();
@@ -234,18 +233,10 @@
             tip.jobHasFinished();
         }
 
-        // Wait for them to die and report in
-        try {
-            Thread.sleep(5000);
-        } catch (InterruptedException ie) {
-        }
-
-        //
         // Shutdown local RPC servers.  Do them
         // in parallel, as RPC servers can take a long
         // time to shutdown.  (They need to wait a full
         // RPC timeout, which might be 10-30 seconds.)
-        //
         new Thread() {
             public void run() {
                 if (taskReportServer != null) {
@@ -254,11 +245,6 @@
                 }
             }
         }.start();
-
-        if (mapOutputServer != null) {
-            mapOutputServer.stop();
-            mapOutputServer = null;
-        }
 
         this.running = false;
         

Modified: lucene/hadoop/trunk/src/test/org/apache/hadoop/dfs/MiniDFSCluster.java
URL: http://svn.apache.org/viewvc/lucene/hadoop/trunk/src/test/org/apache/hadoop/dfs/MiniDFSCluster.java?view=diff&rev=440864&r1=440863&r2=440864
==============================================================================
--- lucene/hadoop/trunk/src/test/org/apache/hadoop/dfs/MiniDFSCluster.java (original)
+++ lucene/hadoop/trunk/src/test/org/apache/hadoop/dfs/MiniDFSCluster.java Wed Sep  6 13:50:11
2006
@@ -113,7 +113,7 @@
     conf.setInt("dfs.replication", 1);
     // this timeout seems to control the minimum time for the test, so
     // decrease it considerably.
-    conf.setInt("ipc.client.timeout", 2000);
+    conf.setInt("ipc.client.timeout", 1000);
     NameNode.format(conf);
     nameNode = new NameNodeRunner();
     nameNodeThread = new Thread(nameNode);
@@ -129,7 +129,7 @@
     while (!nameNode.isUp()) {
       try {                                     // let daemons get started
         System.out.println("waiting for dfs minicluster to start");
-        Thread.sleep(2000);
+        Thread.sleep(1000);
       } catch(InterruptedException e) {
       }
     }



Mime
View raw message