Deprecated
(4.2) use org.
ThreadSafeClientConnManager.
The abstract pool includes a poolLock, which is used to
synchronize access to the internal pool datastructures.
Don't use synchronized for that purpose!
| Modifier and Type | Field and Description |
|---|---|
| protected IdleConnectionHandler | idleConnHandler
Deprecated
as a consequence of
IdleConnectionHandler being deprecated.
|
| protected volatile boolean | isShutDown
Indicates whether this pool is shut down. |
| protected Set | |
| protected Set | |
| private final Log | |
| protected int | |
| protected final Lock | poolLock
The global lock for this pool. |
| protected ReferenceQueue |
| Access | Constructor and Description |
|---|---|
| protected |
| Modifier and Type | Method and Description |
|---|---|
| protected void | closeConnection(final OperatedClientConnection
the connection to close, or conn)null
Deprecated
as a consequence of
Closes a connection from this pool.
OperatedClientConnection being deprecated.
|
| public void | |
| public void | closeIdleConnections(final long
the time the connections should have been idle
in order to be closed now idletime, final TimeUnit the unit for the timeUnit)idletimeCloses idle connections. |
| public abstract void | |
| public void | |
| public abstract void | freeEntry(BasicPoolEntry
the entry for the connection to release entry, boolean true if the entry is deemed
reusable, false otherwise.The duration that the entry should remain free and reusable. validDuration, TimeUnit The unit of time the duration is measured in. timeUnit)
Deprecated
as a consequence of
Returns an entry into the pool.
BasicPoolEntry being deprecated.
|
| public final BasicPoolEntry | Returns: pool entry holding a connection for the routethe route for which to get the connection route, final Object the state state, final long the timeout, 0 or negative for no timeout timeout, final TimeUnit the unit for the timeUnit)timeout,
may be null only if there is no timeout
Deprecated
as a consequence of
Obtains a pool entry with a connection within the given timeout.
BasicPoolEntry being deprecated.
|
| protected abstract void | |
| public void | |
| public abstract PoolEntryRequest | Returns: the entry requestthe route route, Object the state state)
Deprecated
as a consequence of
Returns a new PoolEntryRequest being deprecated.
PoolEntryRequest, from which a BasicPoolEntry
can be obtained, or the request can be aborted.
|
| public void |
| idleConnHandler | back to summary |
|---|---|
| protected IdleConnectionHandler idleConnHandler
Deprecated as a consequence of | |
| isShutDown | back to summary |
|---|---|
| protected volatile boolean isShutDown Indicates whether this pool is shut down. | |
| issuedConnections | back to summary |
|---|---|
| protected Set<BasicPoolEntryRef> issuedConnections | |
| leasedConnections | back to summary |
|---|---|
| protected Set<BasicPoolEntry> leasedConnections | |
| log | back to summary |
|---|---|
| private final Log log | |
| numConnections | back to summary |
|---|---|
| protected int numConnections | |
| poolLock | back to summary |
|---|---|
| protected final Lock poolLock The global lock for this pool. | |
| refQueue | back to summary |
|---|---|
| protected ReferenceQueue<Object> refQueue | |
| AbstractConnPool | back to summary |
|---|---|
| protected AbstractConnPool() Creates a new connection pool. | |
| closeConnection | back to summary |
|---|---|
| protected void closeConnection(final OperatedClientConnection conn)
Deprecated as a consequence of Closes a connection from this pool.
| |
| closeExpiredConnections | back to summary |
|---|---|
| public void closeExpiredConnections() | |
| closeIdleConnections | back to summary |
|---|---|
| public void closeIdleConnections(final long idletime, final TimeUnit timeUnit) Closes idle connections.
| |
| deleteClosedConnections | back to summary |
|---|---|
| public abstract void deleteClosedConnections() Deletes all entries for closed connections. | |
| enableConnectionGC | back to summary |
|---|---|
| public void enableConnectionGC() throws IllegalStateException | |
| freeEntry | back to summary |
|---|---|
| public abstract void freeEntry(BasicPoolEntry entry, boolean reusable, long validDuration, TimeUnit timeUnit)
Deprecated as a consequence of Returns an entry into the pool. The connection of the entry is expected to be in a suitable state, either open and re-usable, or closed. The pool will not make any attempt to determine whether it can be re-used or not.
| |
| getEntry | back to summary |
|---|---|
| public final BasicPoolEntry getEntry(final HttpRoute route, final Object state, final long timeout, final TimeUnit timeUnit) throws ConnectionPoolTimeoutException, InterruptedException
Deprecated as a consequence of Obtains a pool entry with a connection within the given timeout.
| |
| handleLostEntry | back to summary |
|---|---|
| protected abstract void handleLostEntry(HttpRoute route) | |
| handleReference | back to summary |
|---|---|
| public void handleReference(final Reference<?> ref) | |
| requestPoolEntry | back to summary |
|---|---|
| public abstract PoolEntryRequest requestPoolEntry(HttpRoute route, Object state)
Deprecated as a consequence of Returns a new
| |
| shutdown | back to summary |
|---|---|
| public void shutdown() Shuts down this pool and all associated resources. Overriding methods MUST call the implementation here! | |