You are viewing a plain text version of this content. The canonical link for it is here.
Posted to hdfs-commits@hadoop.apache.org by sz...@apache.org on 2013/07/26 12:59:21 UTC
svn commit: r1507259 -
/hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/NameNodeProxies.java
Author: szetszwo
Date: Fri Jul 26 10:59:20 2013
New Revision: 1507259
URL: http://svn.apache.org/r1507259
Log:
HADOOP-9756. Remove the deprecated getServer(..) methods from RPC. Contributed by Junping Du
Modified:
hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/NameNodeProxies.java
Modified: hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/NameNodeProxies.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/NameNodeProxies.java?rev=1507259&r1=1507258&r2=1507259&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/NameNodeProxies.java (original)
+++ hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/NameNodeProxies.java Fri Jul 26 10:59:20 2013
@@ -344,7 +344,6 @@ public class NameNodeProxies {
}
/** Creates the Failover proxy provider instance*/
- @SuppressWarnings("unchecked")
private static <T> FailoverProxyProvider<T> createFailoverProxyProvider(
Configuration conf, Class<FailoverProxyProvider<T>> failoverProxyProviderClass,
Class<T> xface, URI nameNodeUri) throws IOException {
@@ -354,9 +353,9 @@ public class NameNodeProxies {
try {
Constructor<FailoverProxyProvider<T>> ctor = failoverProxyProviderClass
.getConstructor(Configuration.class, URI.class, Class.class);
- FailoverProxyProvider<?> provider = ctor.newInstance(conf, nameNodeUri,
+ FailoverProxyProvider<T> provider = ctor.newInstance(conf, nameNodeUri,
xface);
- return (FailoverProxyProvider<T>) provider;
+ return provider;
} catch (Exception e) {
String message = "Couldn't create proxy provider " + failoverProxyProviderClass;
if (LOG.isDebugEnabled()) {