MAPREDUCE-6483. Replace deprecated method NameNode.getUri() with DFSUtilClient.getNNUri() in TestMRCredentials. Contributed by Mingliang Liu.
This commit is contained in:
parent
9240a021fc
commit
0971503522
|
@ -112,6 +112,9 @@ Release 2.8.0 - UNRELEASED
|
|||
MAPREDUCE-6477. Replace usage of deprecated NameNode.DEFAULT_PORT in
|
||||
TestFileSystem. (Mingliang Liu via wheat9)
|
||||
|
||||
MAPREDUCE-6483. Replace deprecated method NameNode.getUri() with
|
||||
DFSUtilClient.getNNUri() in TestMRCredentials. (Mingliang Liu via wheat9)
|
||||
|
||||
OPTIMIZATIONS
|
||||
|
||||
MAPREDUCE-6376. Add avro binary support for jhist files (Ray Chiang via
|
||||
|
|
|
@ -29,6 +29,7 @@ import java.net.URI;
|
|||
|
||||
import org.apache.hadoop.conf.Configuration;
|
||||
import org.apache.hadoop.fs.FileSystem;
|
||||
import org.apache.hadoop.hdfs.DFSUtilClient;
|
||||
import org.apache.hadoop.hdfs.MiniDFSCluster;
|
||||
import org.apache.hadoop.hdfs.server.namenode.NameNode;
|
||||
import org.apache.hadoop.mapred.JobConf;
|
||||
|
@ -111,9 +112,8 @@ public class TestMRCredentials {
|
|||
Configuration jobConf = new JobConf(mrCluster.getConfig());
|
||||
|
||||
// provide namenodes names for the job to get the delegation tokens for
|
||||
//String nnUri = dfsCluster.getNameNode().getUri(namenode).toString();
|
||||
NameNode nn = dfsCluster.getNameNode();
|
||||
URI nnUri = NameNode.getUri(nn.getNameNodeAddress());
|
||||
URI nnUri = DFSUtilClient.getNNUri(nn.getNameNodeAddress());
|
||||
jobConf.set(JobContext.JOB_NAMENODES, nnUri + "," + nnUri.toString());
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue