You are viewing a plain text version of this content. The canonical link for it is here.
Posted to hdfs-commits@hadoop.apache.org by ki...@apache.org on 2013/06/04 23:43:26 UTC
svn commit: r1489634 - in
/hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs: CHANGES.txt
src/main/java/org/apache/hadoop/hdfs/server/blockmanagement/BlockManager.java
Author: kihwal
Date: Tue Jun 4 21:43:08 2013
New Revision: 1489634
URL: http://svn.apache.org/r1489634
Log:
HDFS-4840. ReplicationMonitor gets NPE during shutdown. Contributed by Kihwal Lee.
Modified:
hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt
hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/blockmanagement/BlockManager.java
Modified: hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt?rev=1489634&r1=1489633&r2=1489634&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt (original)
+++ hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt Tue Jun 4 21:43:08 2013
@@ -561,6 +561,8 @@ Release 2.1.0-beta - UNRELEASED
HDFS-4382. Fix typo MAX_NOT_CHANGED_INTERATIONS. (Ted Yu via suresh)
+ HDFS-4840. ReplicationMonitor gets NPE during shutdown. (kihwal)
+
BREAKDOWN OF HDFS-347 SUBTASKS AND RELATED JIRAS
HDFS-4353. Encapsulate connections to peers in Peer and PeerServer classes.
Modified: hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/blockmanagement/BlockManager.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/blockmanagement/BlockManager.java?rev=1489634&r1=1489633&r2=1489634&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/blockmanagement/BlockManager.java (original)
+++ hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/blockmanagement/BlockManager.java Tue Jun 4 21:43:08 2013
@@ -3094,10 +3094,15 @@ assert storedBlock.findDatanode(dn) < 0
computeDatanodeWork();
processPendingReplications();
Thread.sleep(replicationRecheckInterval);
- } catch (InterruptedException ie) {
- LOG.warn("ReplicationMonitor thread received InterruptedException.", ie);
- break;
} catch (Throwable t) {
+ if (!namesystem.isRunning()) {
+ LOG.info("Stopping ReplicationMonitor.");
+ if (!(t instanceof InterruptedException)) {
+ LOG.info("ReplicationMonitor received an exception"
+ + " while shutting down.", t);
+ }
+ break;
+ }
LOG.fatal("ReplicationMonitor thread received Runtime exception. ", t);
terminate(1, t);
}