Class ConnectionPoolManager
- java.lang.Object
-
- org.apache.manifoldcf.core.jdbcpool.ConnectionPoolManager
-
public class ConnectionPoolManager extends java.lang.ObjectAn instance of this class manages a number of (independent) connection pools.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description protected classConnectionPoolManager.ConnectionCloserThread
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String_rcsidprotected ConnectionPoolManager.ConnectionCloserThreadconnectionCloserThreadprotected booleandebugprotected java.util.Map<java.lang.String,ConnectionPool>poolMapprotected java.util.concurrent.atomic.AtomicBooleanshuttingDown
-
Constructor Summary
Constructors Constructor Description ConnectionPoolManager(int count, boolean debug)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ConnectionPooladdAlias(java.lang.String poolKey, java.lang.String driverClassName, java.lang.String dbURL, java.lang.String userName, java.lang.String password, int maxSize, long expiration)Set up a pool with a given key.protected voidcleanupExpiredConnections(long cleanupTime)voidflush()ConnectionPoolgetPool(java.lang.String poolKey)Look for a pool with a given key.voidshutdown()
-
-
-
Field Detail
-
_rcsid
public static final java.lang.String _rcsid
- See Also:
- Constant Field Values
-
poolMap
protected final java.util.Map<java.lang.String,ConnectionPool> poolMap
-
connectionCloserThread
protected final ConnectionPoolManager.ConnectionCloserThread connectionCloserThread
-
shuttingDown
protected volatile java.util.concurrent.atomic.AtomicBoolean shuttingDown
-
debug
protected final boolean debug
-
-
Constructor Detail
-
ConnectionPoolManager
public ConnectionPoolManager(int count, boolean debug) throws ManifoldCFException- Throws:
ManifoldCFException
-
-
Method Detail
-
getPool
public ConnectionPool getPool(java.lang.String poolKey)
Look for a pool with a given key.
-
addAlias
public ConnectionPool addAlias(java.lang.String poolKey, java.lang.String driverClassName, java.lang.String dbURL, java.lang.String userName, java.lang.String password, int maxSize, long expiration) throws java.lang.ClassNotFoundException, java.lang.InstantiationException, java.lang.IllegalAccessException
Set up a pool with a given key.- Throws:
java.lang.ClassNotFoundExceptionjava.lang.InstantiationExceptionjava.lang.IllegalAccessException
-
flush
public void flush()
-
shutdown
public void shutdown()
-
cleanupExpiredConnections
protected void cleanupExpiredConnections(long cleanupTime)
-
-