hadoop-common-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tomwh...@apache.org
Subject svn commit: r526392 - in /lucene/hadoop/trunk: CHANGES.txt src/java/org/apache/hadoop/dfs/FSNamesystem.java
Date Sat, 07 Apr 2007 07:47:53 GMT
Author: tomwhite
Date: Sat Apr  7 00:47:53 2007
New Revision: 526392

URL: http://svn.apache.org/viewvc?view=rev&rev=526392
Log:
HADOOP-1149.  Improve DFS Scalability: make processOverReplicatedBlock() a no-op if blocks
are not over-replicated.  Contributed by Raghu Angadi.

Modified:
    lucene/hadoop/trunk/CHANGES.txt
    lucene/hadoop/trunk/src/java/org/apache/hadoop/dfs/FSNamesystem.java

Modified: lucene/hadoop/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/lucene/hadoop/trunk/CHANGES.txt?view=diff&rev=526392&r1=526391&r2=526392
==============================================================================
--- lucene/hadoop/trunk/CHANGES.txt (original)
+++ lucene/hadoop/trunk/CHANGES.txt Sat Apr  7 00:47:53 2007
@@ -123,6 +123,10 @@
     long-running unit tests may be automatically terminated.
     (Nigel Daley via cutting)
 
+39. HADOOP-1149.  Improve DFS Scalability: make 
+    processOverReplicatedBlock() a no-op if blocks are not 
+    over-replicated.  (Raghu Angadi via tomwhite)
+
 
 Release 0.12.3 - 2007-04-06
 

Modified: lucene/hadoop/trunk/src/java/org/apache/hadoop/dfs/FSNamesystem.java
URL: http://svn.apache.org/viewvc/lucene/hadoop/trunk/src/java/org/apache/hadoop/dfs/FSNamesystem.java?view=diff&rev=526392&r1=526391&r2=526392
==============================================================================
--- lucene/hadoop/trunk/src/java/org/apache/hadoop/dfs/FSNamesystem.java (original)
+++ lucene/hadoop/trunk/src/java/org/apache/hadoop/dfs/FSNamesystem.java Sat Apr  7 00:47:53
2007
@@ -2198,8 +2198,10 @@
             // they simply take up all the space in the log file 
             // So I set the level to be trace
             //
-            NameNode.stateChangeLog.trace("BLOCK* NameSystem.addStoredBlock: "
+            if ( NameNode.stateChangeLog.isTraceEnabled() ) {
+              NameNode.stateChangeLog.trace("BLOCK* NameSystem.addStoredBlock: "
                     +"blockMap updated: "+node.getName()+" is added to "+block.getBlockName()
);
+            }
         } else {
             NameNode.stateChangeLog.warn("BLOCK* NameSystem.addStoredBlock: "
                     + "Redundant addStoredBlock request received for " 
@@ -2224,7 +2226,9 @@
         } else {
           neededReplications.update(block, curReplicaDelta, 0);
         }
-        proccessOverReplicatedBlock( block, fileReplication );
+        if ( numCurrentReplica > fileReplication ) {
+          proccessOverReplicatedBlock( block, fileReplication );
+        }
         return block;
     }
     
@@ -2360,9 +2364,11 @@
                 "Unexpected exception.  Got blockReceived message from node " 
                 + block.getBlockName() + ", but there is no info for it");
         }
-
-        NameNode.stateChangeLog.debug("BLOCK* NameSystem.blockReceived: "
+        
+        if ( NameNode.stateChangeLog.isDebugEnabled() ) {
+          NameNode.stateChangeLog.debug("BLOCK* NameSystem.blockReceived: "
                 +block.getBlockName()+" is received from " + nodeID.getName() );
+        }
 
         // Check if this datanode should actually be shutdown instead.
         if (shouldNodeShutdown(node)) {
@@ -2589,7 +2595,7 @@
             recentInvalidateSets.put(nodeID.getStorageID(), invalidateSet);
         }
         
-        if (NameNode.stateChangeLog.isInfoEnabled()) {
+        if (NameNode.stateChangeLog.isDebugEnabled()) {
             StringBuffer blockList = new StringBuffer();
             for (int i = 0; i < sendBlock.size(); i++) {
                 blockList.append(' ');



Mime
View raw message