|
@@ -3773,7 +3773,7 @@ public class FSNamesystem implements Namesystem, FSClusterStats,
|
|
|
final long diff = fileINode.getPreferredBlockSize() - commitBlock.getNumBytes();
|
|
|
if (diff > 0) {
|
|
|
try {
|
|
|
- String path = leaseManager.findPath(fileINode);
|
|
|
+ String path = fileINode.getFullPathName();
|
|
|
dir.updateSpaceConsumed(path, 0, -diff*fileINode.getFileReplication());
|
|
|
} catch (IOException e) {
|
|
|
LOG.warn("Unexpected exception while updating disk space.", e);
|
|
@@ -3978,7 +3978,7 @@ public class FSNamesystem implements Namesystem, FSClusterStats,
|
|
|
BlockInfo storedBlock)
|
|
|
throws IOException {
|
|
|
|
|
|
- String src = leaseManager.findPath(pendingFile);
|
|
|
+ String src = pendingFile.getFullPathName();
|
|
|
|
|
|
// commit the last block and complete it if it has minimum replicas
|
|
|
commitOrCompleteLastBlock(pendingFile, storedBlock);
|
|
@@ -4000,7 +4000,7 @@ public class FSNamesystem implements Namesystem, FSClusterStats,
|
|
|
@VisibleForTesting
|
|
|
String persistBlocks(INodeFileUnderConstruction pendingFile,
|
|
|
boolean logRetryCache) throws IOException {
|
|
|
- String src = leaseManager.findPath(pendingFile);
|
|
|
+ String src = pendingFile.getFullPathName();
|
|
|
dir.persistBlocks(src, pendingFile, logRetryCache);
|
|
|
return src;
|
|
|
}
|
|
@@ -5929,7 +5929,7 @@ public class FSNamesystem implements Namesystem, FSClusterStats,
|
|
|
.getDatanodeStorageInfos(newNodes, newStorageIDs);
|
|
|
blockinfo.setExpectedLocations(storages);
|
|
|
|
|
|
- String src = leaseManager.findPath(pendingFile);
|
|
|
+ String src = pendingFile.getFullPathName();
|
|
|
dir.persistBlocks(src, pendingFile, logRetryCache);
|
|
|
}
|
|
|
|