HTTPCLIENT-622 with minor modifications
git-svn-id: https://svn.apache.org/repos/asf/jakarta/httpcomponents/httpclient/trunk@498133 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
613fb5221d
commit
3d8d85a915
|
@ -610,6 +610,8 @@ public class MultiThreadedHttpConnectionManager implements HttpConnectionManager
|
|||
public synchronized void handleLostConnection(HostConfiguration config) {
|
||||
HostConnectionPool hostPool = getHostPool(config);
|
||||
hostPool.numConnections--;
|
||||
if (hostPool.numConnections < 1)
|
||||
mapHosts.remove(config);
|
||||
|
||||
numConnections--;
|
||||
notifyWaitingThread(config);
|
||||
|
@ -715,6 +717,8 @@ public class MultiThreadedHttpConnectionManager implements HttpConnectionManager
|
|||
hostPool.freeConnections.remove(connection);
|
||||
hostPool.numConnections--;
|
||||
numConnections--;
|
||||
if (hostPool.numConnections < 1)
|
||||
mapHosts.remove(connectionConfiguration);
|
||||
|
||||
// remove the connection from the timeout handler
|
||||
idleConnectionHandler.remove(connection);
|
||||
|
|
Loading…
Reference in New Issue