public abstract class AbstractConnectionPool extends Object implements ConnectionPool, Dumpable
| Modifier | Constructor and Description |
|---|---|
protected |
AbstractConnectionPool(Destination destination,
int maxConnections,
Callback requester) |
| Modifier and Type | Method and Description |
|---|---|
Connection |
acquire() |
protected void |
acquired(Connection connection) |
protected abstract Connection |
activate() |
protected Connection |
active(Connection connection) |
void |
close() |
protected void |
close(Collection<Connection> connections) |
String |
dump() |
int |
getConnectionCount() |
int |
getMaxConnectionCount() |
protected boolean |
idle(Connection connection,
boolean close) |
boolean |
isClosed() |
boolean |
isEmpty() |
protected abstract void |
onCreated(Connection connection) |
protected void |
proceed() |
protected void |
released(Connection connection) |
protected void |
removed(Connection connection) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitisActive, release, removeprotected AbstractConnectionPool(Destination destination, int maxConnections, Callback requester)
@ManagedAttribute(value="The max number of connections", readonly=true) public int getMaxConnectionCount()
@ManagedAttribute(value="The number of connections", readonly=true) public int getConnectionCount()
public boolean isEmpty()
isEmpty in interface ConnectionPoolpublic boolean isClosed()
isClosed in interface ConnectionPoolpublic Connection acquire()
acquire in interface ConnectionPoolprotected abstract void onCreated(Connection connection)
protected void proceed()
protected abstract Connection activate()
protected Connection active(Connection connection)
protected void acquired(Connection connection)
protected boolean idle(Connection connection, boolean close)
protected void released(Connection connection)
protected void removed(Connection connection)
public void close()
close in interface Closeableclose in interface AutoCloseableclose in interface ConnectionPoolprotected void close(Collection<Connection> connections)
Copyright © 1995–2017 Webtide. All rights reserved.