You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@manifoldcf.apache.org by kw...@apache.org on 2013/02/05 14:27:45 UTC

svn commit: r1442578 - /manifoldcf/trunk/framework/core/src/main/java/org/apache/manifoldcf/core/jdbcpool/ConnectionPool.java

Author: kwright
Date: Tue Feb  5 13:27:45 2013
New Revision: 1442578

URL: http://svn.apache.org/viewvc?rev=1442578&view=rev
Log:
Synchronizer around used connection dump

Modified:
    manifoldcf/trunk/framework/core/src/main/java/org/apache/manifoldcf/core/jdbcpool/ConnectionPool.java

Modified: manifoldcf/trunk/framework/core/src/main/java/org/apache/manifoldcf/core/jdbcpool/ConnectionPool.java
URL: http://svn.apache.org/viewvc/manifoldcf/trunk/framework/core/src/main/java/org/apache/manifoldcf/core/jdbcpool/ConnectionPool.java?rev=1442578&r1=1442577&r2=1442578&view=diff
==============================================================================
--- manifoldcf/trunk/framework/core/src/main/java/org/apache/manifoldcf/core/jdbcpool/ConnectionPool.java (original)
+++ manifoldcf/trunk/framework/core/src/main/java/org/apache/manifoldcf/core/jdbcpool/ConnectionPool.java Tue Feb  5 13:27:45 2013
@@ -90,10 +90,13 @@ public class ConnectionPool
           // If properly configured, we really shouldn't be getting here.
           if (debug)
           {
-            Logging.db.warn("Out of db connections, list of outstanding ones follows.");
-            for (WrappedConnection c : outstandingConnections)
+            synchronized (outstandingConnections)
             {
-              Logging.db.warn("Found a possibly leaked db connection",c.getInstantiationException());
+              Logging.db.warn("Out of db connections, list of outstanding ones follows.");
+              for (WrappedConnection c : outstandingConnections)
+              {
+                Logging.db.warn("Found a possibly leaked db connection",c.getInstantiationException());
+              }
             }
           }
           // Wait until kicked; we hope something will free up...