hadoop-common-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tomwh...@apache.org
Subject svn commit: r533013 - in /lucene/hadoop/trunk: ./ src/java/org/apache/hadoop/ipc/ src/java/org/apache/hadoop/util/ src/test/org/apache/hadoop/dfs/
Date Fri, 27 Apr 2007 08:29:53 GMT
Author: tomwhite
Date: Fri Apr 27 01:29:52 2007
New Revision: 533013

URL: http://svn.apache.org/viewvc?view=rev&rev=533013
Log:
HADOOP-1294.  Fix unchecked warnings in main Hadoop code under Java 6.

Modified:
    lucene/hadoop/trunk/CHANGES.txt
    lucene/hadoop/trunk/src/java/org/apache/hadoop/ipc/RPC.java
    lucene/hadoop/trunk/src/java/org/apache/hadoop/util/ProgramDriver.java
    lucene/hadoop/trunk/src/java/org/apache/hadoop/util/ReflectionUtils.java
    lucene/hadoop/trunk/src/java/org/apache/hadoop/util/RunJar.java
    lucene/hadoop/trunk/src/test/org/apache/hadoop/dfs/ClusterTestDFS.java

Modified: lucene/hadoop/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/lucene/hadoop/trunk/CHANGES.txt?view=diff&rev=533013&r1=533012&r2=533013
==============================================================================
--- lucene/hadoop/trunk/CHANGES.txt (original)
+++ lucene/hadoop/trunk/CHANGES.txt Fri Apr 27 01:29:52 2007
@@ -282,6 +282,9 @@
     shuffle, sort and reduce.  Use this to implement reduce=NONE
     option in contrib/streaming.  (Runping Qi via cutting)
 
+84. HADOOP-1294.  Fix unchecked warnings in main Hadoop code under 
+    Java 6.  (tomwhite)
+
 
 Release 0.12.3 - 2007-04-06
 

Modified: lucene/hadoop/trunk/src/java/org/apache/hadoop/ipc/RPC.java
URL: http://svn.apache.org/viewvc/lucene/hadoop/trunk/src/java/org/apache/hadoop/ipc/RPC.java?view=diff&rev=533013&r1=533012&r2=533013
==============================================================================
--- lucene/hadoop/trunk/src/java/org/apache/hadoop/ipc/RPC.java (original)
+++ lucene/hadoop/trunk/src/java/org/apache/hadoop/ipc/RPC.java Fri Apr 27 01:29:52 2007
@@ -296,7 +296,7 @@
   /** An RPC Server. */
   public static class Server extends org.apache.hadoop.ipc.Server {
     private Object instance;
-    private Class implementation;
+    private Class<?> implementation;
     private boolean verbose;
 
     /** Construct an RPC server.

Modified: lucene/hadoop/trunk/src/java/org/apache/hadoop/util/ProgramDriver.java
URL: http://svn.apache.org/viewvc/lucene/hadoop/trunk/src/java/org/apache/hadoop/util/ProgramDriver.java?view=diff&rev=533013&r1=533012&r2=533013
==============================================================================
--- lucene/hadoop/trunk/src/java/org/apache/hadoop/util/ProgramDriver.java (original)
+++ lucene/hadoop/trunk/src/java/org/apache/hadoop/util/ProgramDriver.java Fri Apr 27 01:29:52
2007
@@ -42,7 +42,7 @@
      
   static private class ProgramDescription {
 	
-    static final Class[] paramTypes = new Class[] {String[].class};
+    static final Class<?>[] paramTypes = new Class<?>[] {String[].class};
 	
     /**
      * Create a description of an example program.
@@ -51,7 +51,7 @@
      * @throws SecurityException if we can't use reflection
      * @throws NoSuchMethodException if the class doesn't have a main method
      */
-    public ProgramDescription(Class mainClass, 
+    public ProgramDescription(Class<?> mainClass, 
                               String description)
       throws SecurityException, NoSuchMethodException {
       this.main = mainClass.getMethod("main", paramTypes);

Modified: lucene/hadoop/trunk/src/java/org/apache/hadoop/util/ReflectionUtils.java
URL: http://svn.apache.org/viewvc/lucene/hadoop/trunk/src/java/org/apache/hadoop/util/ReflectionUtils.java?view=diff&rev=533013&r1=533012&r2=533013
==============================================================================
--- lucene/hadoop/trunk/src/java/org/apache/hadoop/util/ReflectionUtils.java (original)
+++ lucene/hadoop/trunk/src/java/org/apache/hadoop/util/ReflectionUtils.java Fri Apr 27 01:29:52
2007
@@ -66,7 +66,7 @@
    * @param conf Configuration
    * @return a new object
    */
-  public static Object newInstance(Class theClass, Configuration conf) {
+  public static Object newInstance(Class<?> theClass, Configuration conf) {
     Object result;
     try {
       Constructor meth = CONSTRUCTOR_CACHE.get(theClass);

Modified: lucene/hadoop/trunk/src/java/org/apache/hadoop/util/RunJar.java
URL: http://svn.apache.org/viewvc/lucene/hadoop/trunk/src/java/org/apache/hadoop/util/RunJar.java?view=diff&rev=533013&r1=533012&r2=533013
==============================================================================
--- lucene/hadoop/trunk/src/java/org/apache/hadoop/util/RunJar.java (original)
+++ lucene/hadoop/trunk/src/java/org/apache/hadoop/util/RunJar.java Fri Apr 27 01:29:52 2007
@@ -145,7 +145,7 @@
       new URLClassLoader(classPath.toArray(new URL[0]));
 
     Thread.currentThread().setContextClassLoader(loader);
-    Class mainClass = Class.forName(mainClassName, true, loader);
+    Class<?> mainClass = Class.forName(mainClassName, true, loader);
     Method main = mainClass.getMethod("main", new Class[] {
       Array.newInstance(String.class, 0).getClass()
     });

Modified: lucene/hadoop/trunk/src/test/org/apache/hadoop/dfs/ClusterTestDFS.java
URL: http://svn.apache.org/viewvc/lucene/hadoop/trunk/src/test/org/apache/hadoop/dfs/ClusterTestDFS.java?view=diff&rev=533013&r1=533012&r2=533013
==============================================================================
--- lucene/hadoop/trunk/src/test/org/apache/hadoop/dfs/ClusterTestDFS.java (original)
+++ lucene/hadoop/trunk/src/test/org/apache/hadoop/dfs/ClusterTestDFS.java Fri Apr 27 01:29:52
2007
@@ -435,8 +435,8 @@
         // lazy init
         String rndDataGenClassname =
           conf.get("hadoop.random.class", "java.util.Random");
-        Class clazz = Class.forName(rndDataGenClassname);
-        randomDataGeneratorCtor = clazz.getConstructor(new Class[]{Long.TYPE});
+        Class<?> clazz = Class.forName(rndDataGenClassname);
+        randomDataGeneratorCtor = clazz.getConstructor(Long.TYPE);
       }
 
       if (randomDataGeneratorCtor != null) {



Mime
View raw message