|
@@ -50,8 +50,6 @@ import org.apache.hadoop.io.MultipleIOException;
|
|
|
import org.apache.hadoop.security.SecurityUtil;
|
|
|
import org.apache.hadoop.security.UserGroupInformation;
|
|
|
import org.apache.hadoop.security.token.Token;
|
|
|
-import org.apache.hadoop.security.token.SecretManager.InvalidToken;
|
|
|
-import org.apache.hadoop.security.token.delegation.AbstractDelegationTokenIdentifier;
|
|
|
import org.apache.hadoop.util.Progressable;
|
|
|
import org.apache.hadoop.util.ReflectionUtils;
|
|
|
|
|
@@ -367,6 +365,7 @@ public abstract class FileSystem extends Configured implements Closeable {
|
|
|
* @throws IOException
|
|
|
*/
|
|
|
@InterfaceAudience.LimitedPrivate({"HDFS", "MapReduce"})
|
|
|
+ @Deprecated
|
|
|
public Token<?> getDelegationToken(String renewer) throws IOException {
|
|
|
return null;
|
|
|
}
|
|
@@ -379,11 +378,12 @@ public abstract class FileSystem extends Configured implements Closeable {
|
|
|
*
|
|
|
* @param renewer the account name that is allowed to renew the token.
|
|
|
* @return list of new delegation tokens
|
|
|
+ * If delegation tokens not supported then return a list of size zero.
|
|
|
* @throws IOException
|
|
|
*/
|
|
|
@InterfaceAudience.LimitedPrivate( { "HDFS", "MapReduce" })
|
|
|
public List<Token<?>> getDelegationTokens(String renewer) throws IOException {
|
|
|
- return null;
|
|
|
+ return new ArrayList<Token<?>>(0);
|
|
|
}
|
|
|
|
|
|
/** create a file with the provided permission
|
|
@@ -544,9 +544,9 @@ public abstract class FileSystem extends Configured implements Closeable {
|
|
|
* @return fully qualified path
|
|
|
* @throws FileNotFoundException
|
|
|
*/
|
|
|
- public Path resolvePath(final Path p) throws FileNotFoundException {
|
|
|
+ public Path resolvePath(final Path p) throws IOException {
|
|
|
checkPath(p);
|
|
|
- return p; // default is to return the path
|
|
|
+ return getFileStatus(p).getPath();
|
|
|
}
|
|
|
|
|
|
/**
|