HDFS-6783: Merging r1618635 from trunk to branch-2.
git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/branches/branch-2@1618636 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
f9c07bd3f9
commit
e4b1a7696c
|
@ -286,19 +286,19 @@ public class CacheReplicationMonitor extends Thread implements Closeable {
|
|||
private void rescan() throws InterruptedException {
|
||||
scannedDirectives = 0;
|
||||
scannedBlocks = 0;
|
||||
namesystem.writeLock();
|
||||
try {
|
||||
lock.lock();
|
||||
if (shutdown) {
|
||||
throw new InterruptedException("CacheReplicationMonitor was " +
|
||||
"shut down.");
|
||||
namesystem.writeLock();
|
||||
try {
|
||||
lock.lock();
|
||||
if (shutdown) {
|
||||
throw new InterruptedException("CacheReplicationMonitor was " +
|
||||
"shut down.");
|
||||
}
|
||||
curScanCount = completedScanCount + 1;
|
||||
} finally {
|
||||
lock.unlock();
|
||||
}
|
||||
curScanCount = completedScanCount + 1;
|
||||
}
|
||||
finally {
|
||||
lock.unlock();
|
||||
}
|
||||
try {
|
||||
|
||||
resetStatistics();
|
||||
rescanCacheDirectives();
|
||||
rescanCachedBlockMap();
|
||||
|
|
Loading…
Reference in New Issue