manifoldcf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kwri...@apache.org
Subject svn commit: r1550504 - in /manifoldcf/trunk: CHANGES.txt framework/core/src/main/java/org/apache/manifoldcf/core/connectorpool/ConnectorPool.java
Date Thu, 12 Dec 2013 19:43:41 GMT
Author: kwright
Date: Thu Dec 12 19:43:40 2013
New Revision: 1550504

URL: http://svn.apache.org/r1550504
Log:
Fix for CONNECTORS-837.

Modified:
    manifoldcf/trunk/CHANGES.txt
    manifoldcf/trunk/framework/core/src/main/java/org/apache/manifoldcf/core/connectorpool/ConnectorPool.java

Modified: manifoldcf/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/manifoldcf/trunk/CHANGES.txt?rev=1550504&r1=1550503&r2=1550504&view=diff
==============================================================================
--- manifoldcf/trunk/CHANGES.txt (original)
+++ manifoldcf/trunk/CHANGES.txt Thu Dec 12 19:43:40 2013
@@ -3,6 +3,9 @@ $Id$
 
 ======================= 1.5-dev =====================
 
+CONNECTORS-837: Specifying 1 connection causes hang.
+(Karl Wright)
+
 CONNECTORS-836: Use the same thread context in the registered
 shutdown objects.
 (Karl Wright)

Modified: manifoldcf/trunk/framework/core/src/main/java/org/apache/manifoldcf/core/connectorpool/ConnectorPool.java
URL: http://svn.apache.org/viewvc/manifoldcf/trunk/framework/core/src/main/java/org/apache/manifoldcf/core/connectorpool/ConnectorPool.java?rev=1550504&r1=1550503&r2=1550504&view=diff
==============================================================================
--- manifoldcf/trunk/framework/core/src/main/java/org/apache/manifoldcf/core/connectorpool/ConnectorPool.java
(original)
+++ manifoldcf/trunk/framework/core/src/main/java/org/apache/manifoldcf/core/connectorpool/ConnectorPool.java
Thu Dec 12 19:43:40 2013
@@ -572,6 +572,8 @@ public abstract class ConnectorPool<T ex
         // Compute MaximumTarget
         SumClass sumClass = new SumClass(serviceName);
         lockManager.scanServiceData(serviceTypeName, sumClass);
+        //System.out.println("numServices = "+sumClass.getNumServices()+"; globalTarget =
"+sumClass.getGlobalTarget()+"; globalInUse = "+sumClass.getGlobalInUse());
+        
         int numServices = sumClass.getNumServices();
         if (numServices == 0)
           return;
@@ -614,11 +616,13 @@ public abstract class ConnectorPool<T ex
         {
           // We want a fast ramp up, so make this proportional to globalMax
           int increment = globalMax >> 2;
-          if (increment < 0)
+          if (increment == 0)
             increment = 1;
           optimalTarget += increment;
         }
         
+        //System.out.println("maxTarget = "+maximumTarget+"; fairTarget = "+fairTarget+";
optimalTarget = "+optimalTarget);
+
         // Now compute actual target
         int target = maximumTarget;
         if (target > fairTarget)



Mime
View raw message