commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ma...@apache.org
Subject svn commit: r1735260 - in /commons/proper/pool/trunk/src/main/java/org/apache/commons/pool2/impl: GenericKeyedObjectPool.java GenericObjectPool.java
Date Wed, 16 Mar 2016 16:37:02 GMT
Author: markt
Date: Wed Mar 16 16:37:02 2016
New Revision: 1735260

URL: http://svn.apache.org/viewvc?rev=1735260&view=rev
Log:
Partial fix for regression in fix for POOL-303. Remove interrupt calls where they can't help.

Modified:
    commons/proper/pool/trunk/src/main/java/org/apache/commons/pool2/impl/GenericKeyedObjectPool.java
    commons/proper/pool/trunk/src/main/java/org/apache/commons/pool2/impl/GenericObjectPool.java

Modified: commons/proper/pool/trunk/src/main/java/org/apache/commons/pool2/impl/GenericKeyedObjectPool.java
URL: http://svn.apache.org/viewvc/commons/proper/pool/trunk/src/main/java/org/apache/commons/pool2/impl/GenericKeyedObjectPool.java?rev=1735260&r1=1735259&r2=1735260&view=diff
==============================================================================
--- commons/proper/pool/trunk/src/main/java/org/apache/commons/pool2/impl/GenericKeyedObjectPool.java
(original)
+++ commons/proper/pool/trunk/src/main/java/org/apache/commons/pool2/impl/GenericKeyedObjectPool.java
Wed Mar 16 16:37:02 2016
@@ -1009,9 +1009,6 @@ public class GenericKeyedObjectPool<K,T>
             if (maxTotal > -1 && newNumTotal > maxTotal) {
                 numTotal.decrementAndGet();
                 if (getNumIdle() == 0) {
-                    // POOL-303. There may be threads waiting on an object
-                    // return that isn't going to happen. Unblock them.
-                    objectDeque.idleObjects.interuptTakeWaiters();
                     return null;
                 }
                 clearOldest();
@@ -1026,9 +1023,6 @@ public class GenericKeyedObjectPool<K,T>
         if (newCreateCount > maxTotalPerKeySave) {
             numTotal.decrementAndGet();
             objectDeque.getCreateCount().decrementAndGet();
-            // POOL-303. There may be threads waiting on an object return that
-            // isn't going to happen. Unblock them.
-            objectDeque.idleObjects.interuptTakeWaiters();
             return null;
         }
 

Modified: commons/proper/pool/trunk/src/main/java/org/apache/commons/pool2/impl/GenericObjectPool.java
URL: http://svn.apache.org/viewvc/commons/proper/pool/trunk/src/main/java/org/apache/commons/pool2/impl/GenericObjectPool.java?rev=1735260&r1=1735259&r2=1735260&view=diff
==============================================================================
--- commons/proper/pool/trunk/src/main/java/org/apache/commons/pool2/impl/GenericObjectPool.java
(original)
+++ commons/proper/pool/trunk/src/main/java/org/apache/commons/pool2/impl/GenericObjectPool.java
Wed Mar 16 16:37:02 2016
@@ -848,9 +848,6 @@ public class GenericObjectPool<T> extend
         final long newCreateCount = createCount.incrementAndGet();
         if (newCreateCount > localMaxTotal) {
             createCount.decrementAndGet();
-            // POOL-303. There may be threads waiting on an object return that
-            // isn't going to happen. Unblock them.
-            idleObjects.interuptTakeWaiters();
             return null;
         }
 



Mime
View raw message