You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by ma...@apache.org on 2013/01/10 16:08:16 UTC

svn commit: r1431402 - in /commons/proper/pool/trunk/src/test/java/org/apache/commons/pool2/impl: TestGenericKeyedObjectPool.java TestGenericObjectPool.java

Author: markt
Date: Thu Jan 10 15:08:16 2013
New Revision: 1431402

URL: http://svn.apache.org/viewvc?rev=1431402&view=rev
Log:
Fix more IDE warnings

Modified:
    commons/proper/pool/trunk/src/test/java/org/apache/commons/pool2/impl/TestGenericKeyedObjectPool.java
    commons/proper/pool/trunk/src/test/java/org/apache/commons/pool2/impl/TestGenericObjectPool.java

Modified: commons/proper/pool/trunk/src/test/java/org/apache/commons/pool2/impl/TestGenericKeyedObjectPool.java
URL: http://svn.apache.org/viewvc/commons/proper/pool/trunk/src/test/java/org/apache/commons/pool2/impl/TestGenericKeyedObjectPool.java?rev=1431402&r1=1431401&r2=1431402&view=diff
==============================================================================
--- commons/proper/pool/trunk/src/test/java/org/apache/commons/pool2/impl/TestGenericKeyedObjectPool.java (original)
+++ commons/proper/pool/trunk/src/test/java/org/apache/commons/pool2/impl/TestGenericKeyedObjectPool.java Thu Jan 10 15:08:16 2013
@@ -1433,7 +1433,7 @@ public class TestGenericKeyedObjectPool 
         // Check thread was interrupted
         assertTrue(wtt._thrown instanceof InterruptedException);
     }
-    
+
     /**
      * POOL-231 - verify that concurrent invalidates of the same object do not
      * corrupt pool destroyCount.
@@ -1470,7 +1470,8 @@ public class TestGenericKeyedObjectPool 
             targets.add(targ);
             // Launch nThreads threads all trying to invalidate the target
             for (int i = 0; i < nThreads; i++) {
-                threads[i] = new InvalidateThread(pool,key, obj[targ]);
+                threads[i] =
+                        new InvalidateThread(pool,key, obj[targ.intValue()]);
             }
             for (int i = 0; i < nThreads; i++) {
                 new Thread(threads[i]).start();
@@ -1486,7 +1487,7 @@ public class TestGenericKeyedObjectPool 
         }
         Assert.assertEquals(nIterations, pool.getDestroyedCount());
     }
-    
+
     /**
      * Attempts to invalidate an object, swallowing IllegalStateException.
      */
@@ -1500,6 +1501,7 @@ public class TestGenericKeyedObjectPool 
             this.pool = pool;
             this.key = key;
         }
+        @Override
         public void run() {
             try {
                 pool.invalidateObject(key, obj);

Modified: commons/proper/pool/trunk/src/test/java/org/apache/commons/pool2/impl/TestGenericObjectPool.java
URL: http://svn.apache.org/viewvc/commons/proper/pool/trunk/src/test/java/org/apache/commons/pool2/impl/TestGenericObjectPool.java?rev=1431402&r1=1431401&r2=1431402&view=diff
==============================================================================
--- commons/proper/pool/trunk/src/test/java/org/apache/commons/pool2/impl/TestGenericObjectPool.java (original)
+++ commons/proper/pool/trunk/src/test/java/org/apache/commons/pool2/impl/TestGenericObjectPool.java Thu Jan 10 15:08:16 2013
@@ -1100,7 +1100,7 @@ public class TestGenericObjectPool exten
         assertEquals("Total count different than expected.", 0, pool.getNumActive());
         pool.close();
     }
-    
+
     /**
      * POOL-231 - verify that concurrent invalidates of the same object do not
      * corrupt pool destroyCount.
@@ -1135,7 +1135,7 @@ public class TestGenericObjectPool exten
             targets.add(targ);
             // Launch nThreads threads all trying to invalidate the target
             for (int i = 0; i < nThreads; i++) {
-                threads[i] = new InvalidateThread(pool, obj[targ]);
+                threads[i] = new InvalidateThread(pool, obj[targ.intValue()]);
             }
             for (int i = 0; i < nThreads; i++) {
                 new Thread(threads[i]).start();
@@ -1151,7 +1151,7 @@ public class TestGenericObjectPool exten
         }
         Assert.assertEquals(nIterations, pool.getDestroyedCount());
     }
-    
+
     /**
      * Attempts to invalidate an object, swallowing IllegalStateException.
      */
@@ -1163,6 +1163,7 @@ public class TestGenericObjectPool exten
             this.obj = obj;
             this.pool = pool;
         }
+        @Override
         public void run() {
             try {
                 pool.invalidateObject(obj);