public class ExternalConnectionPool extends ConnectionPool
Purpose: This subclass is intended to be used with external connection pools. For these pools, TopLink does not control the pooling behavior. The login should have the usesExternalConnectionPooling set to "true".
DEAD_CHECK_TIME, INITIAL_CONNECTIONS, MAX_CONNECTIONS, MIN_CONNECTIONS, WAIT_TIMEOUT
Constructor and Description |
---|
ExternalConnectionPool()
PUBLIC: Build a new external connection pool.
|
ExternalConnectionPool(java.lang.String name, Login login, ServerSession owner)
PUBLIC: Build a new external connection pool.
|
Modifier and Type | Method and Description |
---|---|
org.eclipse.persistence.internal.databaseaccess.Accessor |
acquireConnection()
INTERNAL: When we acquire a connection from an ExternalConnectionPool we build a new connection (retrieve it from the external pool).
|
boolean |
hasConnectionAvailable()
INTERNAL: Assume true as the driver is responsible for blocking.
|
boolean |
isThereConflictBetweenLoginAndType()
INTERNAL: Checks for a conflict between pool's type and pool's login
|
void |
releaseConnection(org.eclipse.persistence.internal.databaseaccess.Accessor connection)
INTERNAL: When you release an external connection, you simply let it go.
|
void |
setCheckConnections()
INTERNAL: This method is called to indicate that all available connections should be checked.
|
void |
shutDown()
INTERNAL: This mehtod is a no-op for external pools.
|
void |
startUp()
INTERNAL: Build the default connection.
|
addFailoverConnectionPool, failover, getConnectionsAvailable, getFailoverConnectionPools, getInitialNumberOfConnections, getLogin, getMaxNumberOfConnections, getMinNumberOfConnections, getName, getTotalNumberOfConnections, getWaitTimeout, isConnected, isDead, resetConnections, setFailoverConnectionPools, setInitialNumberOfConnections, setIsConnected, setIsDead, setLogin, setMaxNumberOfConnections, setMinNumberOfConnections, setName, setWaitTimeout, toString
public ExternalConnectionPool()
public ExternalConnectionPool(java.lang.String name, Login login, ServerSession owner)
public org.eclipse.persistence.internal.databaseaccess.Accessor acquireConnection() throws ConcurrencyException
acquireConnection
in class ConnectionPool
ConcurrencyException
public boolean hasConnectionAvailable()
hasConnectionAvailable
in class ConnectionPool
public boolean isThereConflictBetweenLoginAndType()
isThereConflictBetweenLoginAndType
in class ConnectionPool
public void releaseConnection(org.eclipse.persistence.internal.databaseaccess.Accessor connection) throws DatabaseException
releaseConnection
in class ConnectionPool
DatabaseException
public void setCheckConnections()
setCheckConnections
in class ConnectionPool
public void shutDown()
shutDown
in class ConnectionPool
public void startUp()
startUp
in class ConnectionPool