Sfoglia il codice sorgente

svn merge -c 1376054 Merging from truk to branch-0.23 to fix HDFS-3817.

git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/branches/branch-0.23@1454588 13f79535-47bb-0310-9956-ffa450edef68
Kihwal Lee 12 anni fa
parent
commit
d7605219cc

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

@@ -12,6 +12,9 @@ Release 0.23.7 - UNRELEASED
     HDFS-4222. NN is unresponsive and loses heartbeats from DNs when 
     configured to use LDAP and LDAP has issues. (Xiaobo Peng, suresh)
 
+    HDFS-3817. Avoid printing SafeModeException stack trace.
+    (Brandon Li via suresh)
+
   OPTIMIZATIONS
     HDFS-2477. Optimize computing the diff between a block report and the
                namenode state. (Tomasz Nykiel via hairong)

+ 3 - 0
hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/namenode/NameNodeRpcServer.java

@@ -162,6 +162,9 @@ class NameNodeRpcServer implements NamenodeProtocols {
     // The rpc-server port can be ephemeral... ensure we have the correct info
     this.rpcAddress = this.server.getListenerAddress(); 
     nn.setRpcServerAddress(conf, rpcAddress);
+
+    // Set terse exception whose stack trace won't be logged
+    this.server.addTerseExceptions(SafeModeException.class);
   }
   
   /**