116117118119120121122123124125126
// corrupt one won't be chosen to be excess one // without 4910 the number of live replicas would be 0: block gets lost assertEquals(1, bm.countNodes(block.getLocalBlock()).liveReplicas()); } } finally { namesystem.writeUnlock(); } } finally { cluster.shutdown(); }
191192193194195196197198199200201
synchronized (hbm) { theDND.setLastUpdate(0); hbm.heartbeatCheck(); } } finally { namesystem.writeUnlock(); } } /** * Change whether the block placement policy will prefer the writer's
118119120121122123124125126127128
cmds = NameNodeAdapter.sendHeartBeat(nodeReg, dd, namesystem) .getCommands(); assertEquals(0, cmds.length); } } finally { namesystem.writeUnlock(); } } finally { cluster.shutdown(); } }
231232233234235236237238239240241
assertEquals(recoveringNodes[0], (DatanodeInfo)dd1); assertEquals(recoveringNodes[1], (DatanodeInfo)dd2); assertEquals(recoveringNodes[2], (DatanodeInfo)dd3); } } finally { namesystem.writeUnlock(); } } finally { cluster.shutdown(); } }
7172737475767778798081
} else { assertEquals(workCount, blockInvalidateLimit); assertEquals(2, bm.computeInvalidateWork(2)); } } finally { namesystem.writeUnlock(); } } finally { cluster.shutdown(); } }
114115116117118119120121122123124
173174175176177178179180181182183
113114115116117118119120121122123
6869707172737475767778
isFailover = sm.failoverInProgress(); heartbeats = sm.getOutStandingHeartbeats(); reports = sm.getOutStandingReports(); } } finally { fsn.writeUnlock(); } // We print the information separately so that we can release the namesystem // lock quickly. PrintWriter out = null;