Class ConnectionPool

  • All Implemented Interfaces:
    org.apache.commons.pool.ObjectPool

    public class ConnectionPool
    extends org.apache.commons.pool.impl.GenericObjectPool
    Represents a connection pool
    • Nested Class Summary

      • Nested classes/interfaces inherited from class org.apache.commons.pool.impl.GenericObjectPool

        org.apache.commons.pool.impl.GenericObjectPool.Config
    • Field Summary

      • Fields inherited from class org.apache.commons.pool.impl.GenericObjectPool

        DEFAULT_LIFO, DEFAULT_MAX_ACTIVE, DEFAULT_MAX_IDLE, DEFAULT_MAX_WAIT, DEFAULT_MIN_EVICTABLE_IDLE_TIME_MILLIS, DEFAULT_MIN_IDLE, DEFAULT_NUM_TESTS_PER_EVICTION_RUN, DEFAULT_SOFT_MIN_EVICTABLE_IDLE_TIME_MILLIS, DEFAULT_TEST_ON_BORROW, DEFAULT_TEST_ON_RETURN, DEFAULT_TEST_WHILE_IDLE, DEFAULT_TIME_BETWEEN_EVICTION_RUNS_MILLIS, DEFAULT_WHEN_EXHAUSTED_ACTION, WHEN_EXHAUSTED_BLOCK, WHEN_EXHAUSTED_FAIL, WHEN_EXHAUSTED_GROW
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      Object borrowObject()  
      void close()  
      void returnObject​(Object obj)  
      • Methods inherited from class org.apache.commons.pool.impl.GenericObjectPool

        addObject, clear, evict, getLifo, getMaxActive, getMaxIdle, getMaxWait, getMinEvictableIdleTimeMillis, getMinIdle, getNumActive, getNumIdle, getNumTestsPerEvictionRun, getSoftMinEvictableIdleTimeMillis, getTestOnBorrow, getTestOnReturn, getTestWhileIdle, getTimeBetweenEvictionRunsMillis, getWhenExhaustedAction, invalidateObject, setConfig, setFactory, setLifo, setMaxActive, setMaxIdle, setMaxWait, setMinEvictableIdleTimeMillis, setMinIdle, setNumTestsPerEvictionRun, setSoftMinEvictableIdleTimeMillis, setTestOnBorrow, setTestOnReturn, setTestWhileIdle, setTimeBetweenEvictionRunsMillis, setWhenExhaustedAction, startEvictor
      • Methods inherited from class org.apache.commons.pool.BaseObjectPool

        assertOpen, isClosed
    • Method Detail

      • borrowObject

        public Object borrowObject()
                            throws ConnectException
        Specified by:
        borrowObject in interface org.apache.commons.pool.ObjectPool
        Overrides:
        borrowObject in class org.apache.commons.pool.impl.GenericObjectPool
        Throws:
        ConnectException
      • returnObject

        public void returnObject​(Object obj)
        Specified by:
        returnObject in interface org.apache.commons.pool.ObjectPool
        Overrides:
        returnObject in class org.apache.commons.pool.impl.GenericObjectPool
      • close

        public void close()
                   throws ConnectException
        Specified by:
        close in interface org.apache.commons.pool.ObjectPool
        Overrides:
        close in class org.apache.commons.pool.impl.GenericObjectPool
        Throws:
        ConnectException