svn merge -c 1398293 from trunk for HDFS-4036. Remove "throw UnresolvedLinkException" from FSDirectory.unprotectedAddFile(..).

git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/branches/branch-2@1398294 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Tsz-wo Sze 2012-10-15 14:08:25 +00:00
parent 1f109df2c6
commit 0822195ff2
2 changed files with 7 additions and 6 deletions

View File

@ -54,6 +54,9 @@ Release 2.0.3-alpha - Unreleased
HDFS-4037. Rename the getReplication() method in BlockCollection to
getBlockReplication(). (szetszwo)
HDFS-4036. Remove "throw UnresolvedLinkException" from
FSDirectory.unprotectedAddFile(..). (Jing Zhao via szetszwo)
OPTIMIZATIONS
BUG FIXES

View File

@ -213,8 +213,9 @@ public class FSDirectory implements Closeable {
/**
* Add the given filename to the fs.
* @throws QuotaExceededException
* @throws FileAlreadyExistsException
* @throws FileAlreadyExistsException
* @throws QuotaExceededException
* @throws UnresolvedLinkException
*/
INodeFileUnderConstruction addFile(String path,
PermissionStatus permissions,
@ -265,8 +266,6 @@ public class FSDirectory implements Closeable {
return newNode;
}
/**
*/
INode unprotectedAddFile( String path,
PermissionStatus permissions,
short replication,
@ -275,8 +274,7 @@ public class FSDirectory implements Closeable {
long preferredBlockSize,
boolean underConstruction,
String clientName,
String clientMachine)
throws UnresolvedLinkException {
String clientMachine) {
INode newNode;
assert hasWriteLock();
if (underConstruction) {