# Class PoolConfig

java.lang.Object
com.mchange.v2.c3p0.PoolConfig

public final class PoolConfig extends Object
Deprecated.
as of c3p0-0.9.1. To manipulate config programmaticall, please use ComboPooledDataSource

Encapsulates all the configuration information required by a c3p0 pooled DataSource.

Newly constructed PoolConfig objects are preset with default values, which you can define yourself (see below), or you can rely on c3p0's built-in defaults. Just create a PoolConfig object, and change only the properties you care about. Then pass it to the `DataSources.pooledDataSource(javax.sql.DataSource, com.mchange.v2.c3p0.PoolConfig)` method, and you're off!

For those interested in the details, configuration properties can be specified in several ways:

1. Any property can be set explicitly by calling the corresponding method on a PoolConfig object.
2. Any property will default to a value defined by a System Property, using the property name shown the table below.
3. Any property not set in either of the above ways will default to a value found in a user-supplied Java properties file, which may be placed in the resource path of the ClassLoader that loaded the c3p0 libraries under the name `/c3p0.properties`.
4. Any property not set in any of the above ways will be defined according c3p0's built-in defaults.

Please see c3p0's main documentation for a description of all available parameters.

## Field Summary

Fields
Modifier and Type
Field
Description
`static final String`
`ACQUIRE_INCREMENT`
Deprecated.
`static final String`
`ACQUIRE_RETRY_ATTEMPTS`
Deprecated.
`static final String`
`ACQUIRE_RETRY_DELAY`
Deprecated.
`static final String`
`AUTO_COMMIT_ON_CLOSE`
Deprecated.
`static final String`
`AUTOMATIC_TEST_TABLE`
Deprecated.
`static final String`
`BREAK_AFTER_ACQUIRE_FAILURE`
Deprecated.
`static final String`
`CHECKOUT_TIMEOUT`
Deprecated.
`static final String`
`CONNECTION_TESTER_CLASS_NAME`
Deprecated.
`static final String`
`DEFAULT_CONFIG_RSRC_PATH`
Deprecated.
`static final String`
`FACTORY_CLASS_LOCATION`
Deprecated.
`static final String`
`FORCE_IGNORE_UNRESOLVED_TRANSACTIONS`
Deprecated.
`static final String`
`IDLE_CONNECTION_TEST_PERIOD`
Deprecated.
`static final String`
`INITIAL_POOL_SIZE`
Deprecated.
`static final String`
`MAX_IDLE_TIME`
Deprecated.
`static final String`
`MAX_POOL_SIZE`
Deprecated.
`static final String`
`MAX_STATEMENTS`
Deprecated.
`static final String`
`MAX_STATEMENTS_PER_CONNECTION`
Deprecated.
`static final String`
`MIN_POOL_SIZE`
Deprecated.
`static final String`
`NUM_HELPER_THREADS`
Deprecated.
`static final String`
`PREFERRED_TEST_QUERY`
Deprecated.
`static final String`
`PROPERTY_CYCLE`
Deprecated.
`static final String`
`TEST_CONNECTION_ON_CHECKIN`
Deprecated.
`static final String`
`TEST_CONNECTION_ON_CHECKOUT`
Deprecated.
`static final String`
`USES_TRADITIONAL_REFLECTIVE_PROXIES`
Deprecated.

## Constructor Summary

Constructors
Constructor
Description
`PoolConfig()`
Deprecated.
`PoolConfig(Properties props)`
Deprecated.

## Method Summary

Modifier and Type
Method
Description
`static int`
`defaultAcquireIncrement()`
Deprecated.
`static int`
`defaultAcquireRetryAttempts()`
Deprecated.
`static int`
`defaultAcquireRetryDelay()`
Deprecated.
`static boolean`
`defaultAutoCommitOnClose()`
Deprecated.
`static String`
`defaultAutomaticTestTable()`
Deprecated.
`static boolean`
`defaultBreakAfterAcquireFailure()`
Deprecated.
`static int`
`defaultCheckoutTimeout()`
Deprecated.
`static String`
`defaultConnectionTesterClassName()`
Deprecated.
`static String`
`defaultFactoryClassLocation()`
Deprecated.
`static boolean`
`defaultForceIgnoreUnresolvedTransactions()`
Deprecated.
`static int`
`defaultIdleConnectionTestPeriod()`
Deprecated.
`static int`
`defaultInitialPoolSize()`
Deprecated.
`static int`
`defaultMaxIdleTime()`
Deprecated.
`static int`
`defaultMaxPoolSize()`
Deprecated.
`static int`
`defaultMaxStatements()`
Deprecated.
`static int`
`defaultMaxStatementsPerConnection()`
Deprecated.
`static int`
`defaultMinPoolSize()`
Deprecated.
`static int`
`defaultNumHelperThreads()`
Deprecated.
`static String`
`defaultPreferredTestQuery()`
Deprecated.
`static int`
`defaultPropertyCycle()`
Deprecated.
`static boolean`
`defaultTestConnectionOnCheckin()`
Deprecated.
`static boolean`
`defaultTestConnectionOnCheckout()`
Deprecated.
`static boolean`
`defaultUsesTraditionalReflectiveProxies()`
Deprecated.
`int`
`getAcquireIncrement()`
Deprecated.
`int`
`getAcquireRetryAttempts()`
Deprecated.
`int`
`getAcquireRetryDelay()`
Deprecated.
`String`
`getAutomaticTestTable()`
Deprecated.
`int`
`getCheckoutTimeout()`
Deprecated.
`String`
`getConnectionTesterClassName()`
Deprecated.
`String`
`getFactoryClassLocation()`
Deprecated.
`int`
`getIdleConnectionTestPeriod()`
Deprecated.
`int`
`getInitialPoolSize()`
Deprecated.
`int`
`getMaxIdleTime()`
Deprecated.
`int`
`getMaxPoolSize()`
Deprecated.
`int`
`getMaxStatements()`
Deprecated.
`int`
`getMaxStatementsPerConnection()`
Deprecated.
`int`
`getMinPoolSize()`
Deprecated.
`int`
`getNumHelperThreads()`
Deprecated.
`String`
`getPreferredTestQuery()`
Deprecated.
`int`
`getPropertyCycle()`
Deprecated.
`boolean`
`getTestConnectionOnCheckout()`
Deprecated.
use isTestConnectionOnCheckout
`boolean`
`isAutoCommitOnClose()`
Deprecated.
`boolean`
`isBreakAfterAcquireFailure()`
Deprecated.
`boolean`
`isForceIgnoreUnresolvedTransactions()`
Deprecated.
`boolean`
`isTestConnectionOnCheckin()`
Deprecated.
`boolean`
`isTestConnectionOnCheckout()`
Deprecated.
`boolean`
`isUsesTraditionalReflectiveProxies()`
Deprecated.
`void`
`setAcquireIncrement(int acquireIncrement)`
Deprecated.
`void`
`setAcquireRetryAttempts(int acquireRetryAttempts)`
Deprecated.
`void`
`setAcquireRetryDelay(int acquireRetryDelay)`
Deprecated.
`void`
`setAutoCommitOnClose(boolean autoCommitOnClose)`
Deprecated.
`void`
`setAutomaticTestTable(String automaticTestTable)`
Deprecated.
`void`
`setBreakAfterAcquireFailure(boolean breakAfterAcquireFailure)`
Deprecated.
`void`
`setCheckoutTimeout(int checkoutTimeout)`
Deprecated.
`void`
`setConnectionTesterClassName(String connectionTesterClassName)`
Deprecated.
`void`
`setFactoryClassLocation(String factoryClassLocation)`
Deprecated.
`void`
`setForceIgnoreUnresolvedTransactions(boolean forceIgnoreUnresolvedTransactions)`
Deprecated.
`void`
`setIdleConnectionTestPeriod(int idleConnectionTestPeriod)`
Deprecated.
`void`
`setInitialPoolSize(int initialPoolSize)`
Deprecated.
`void`
`setMaxIdleTime(int maxIdleTime)`
Deprecated.
`void`
`setMaxPoolSize(int maxPoolSize)`
Deprecated.
`void`
`setMaxStatements(int maxStatements)`
Deprecated.
`void`
`setMaxStatementsPerConnection(int maxStatementsPerConnection)`
Deprecated.
`void`
`setMinPoolSize(int minPoolSize)`
Deprecated.
`void`
`setNumHelperThreads(int numHelperThreads)`
Deprecated.
`void`
`setPreferredTestQuery(String preferredTestQuery)`
Deprecated.
`void`
`setPropertyCycle(int propertyCycle)`
Deprecated.
`void`
`setTestConnectionOnCheckin(boolean testConnectionOnCheckin)`
Deprecated.
`void`
`setTestConnectionOnCheckout(boolean testConnectionOnCheckout)`
Deprecated.
`void`
`setUsesTraditionalReflectiveProxies(boolean usesTraditionalReflectiveProxies)`
Deprecated.

### Methods inherited from class Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Field Details

### INITIAL_POOL_SIZE

public static final String INITIAL_POOL_SIZE
Deprecated.

See Also:
  - Constant Field Values

### MIN_POOL_SIZE

public static final String MIN_POOL_SIZE
Deprecated.

See Also:
  - Constant Field Values

### MAX_POOL_SIZE

public static final String MAX_POOL_SIZE
Deprecated.

See Also:
  - Constant Field Values

### IDLE_CONNECTION_TEST_PERIOD

public static final String IDLE_CONNECTION_TEST_PERIOD
Deprecated.

See Also:
  - Constant Field Values

### MAX_IDLE_TIME

public static final String MAX_IDLE_TIME
Deprecated.

See Also:
  - Constant Field Values

### PROPERTY_CYCLE

public static final String PROPERTY_CYCLE
Deprecated.

See Also:
  - Constant Field Values

### MAX_STATEMENTS

public static final String MAX_STATEMENTS
Deprecated.

See Also:
  - Constant Field Values

### MAX_STATEMENTS_PER_CONNECTION

public static final String MAX_STATEMENTS_PER_CONNECTION
Deprecated.

See Also:
  - Constant Field Values

### CHECKOUT_TIMEOUT

public static final String CHECKOUT_TIMEOUT
Deprecated.

See Also:
  - Constant Field Values

### ACQUIRE_INCREMENT

public static final String ACQUIRE_INCREMENT
Deprecated.

See Also:
  - Constant Field Values

### ACQUIRE_RETRY_ATTEMPTS

public static final String ACQUIRE_RETRY_ATTEMPTS
Deprecated.

See Also:
  - Constant Field Values

### ACQUIRE_RETRY_DELAY

public static final String ACQUIRE_RETRY_DELAY
Deprecated.

See Also:
  - Constant Field Values

### BREAK_AFTER_ACQUIRE_FAILURE

public static final String BREAK_AFTER_ACQUIRE_FAILURE
Deprecated.

See Also:
  - Constant Field Values

### USES_TRADITIONAL_REFLECTIVE_PROXIES

public static final String USES_TRADITIONAL_REFLECTIVE_PROXIES
Deprecated.

See Also:
  - Constant Field Values

### TEST_CONNECTION_ON_CHECKOUT

public static final String TEST_CONNECTION_ON_CHECKOUT
Deprecated.

See Also:
  - Constant Field Values

### TEST_CONNECTION_ON_CHECKIN

public static final String TEST_CONNECTION_ON_CHECKIN
Deprecated.

See Also:
  - Constant Field Values

### CONNECTION_TESTER_CLASS_NAME

public static final String CONNECTION_TESTER_CLASS_NAME
Deprecated.

See Also:
  - Constant Field Values

### AUTOMATIC_TEST_TABLE

public static final String AUTOMATIC_TEST_TABLE
Deprecated.

See Also:
  - Constant Field Values

### AUTO_COMMIT_ON_CLOSE

public static final String AUTO_COMMIT_ON_CLOSE
Deprecated.

See Also:
  - Constant Field Values

### FORCE_IGNORE_UNRESOLVED_TRANSACTIONS

public static final String FORCE_IGNORE_UNRESOLVED_TRANSACTIONS
Deprecated.

See Also:
  - Constant Field Values

### NUM_HELPER_THREADS

public static final String NUM_HELPER_THREADS
Deprecated.

See Also:
  - Constant Field Values

### PREFERRED_TEST_QUERY

public static final String PREFERRED_TEST_QUERY
Deprecated.

See Also:
  - Constant Field Values

### FACTORY_CLASS_LOCATION

public static final String FACTORY_CLASS_LOCATION
Deprecated.

See Also:
  - Constant Field Values

### DEFAULT_CONFIG_RSRC_PATH

public static final String DEFAULT_CONFIG_RSRC_PATH
Deprecated.

See Also:
  - Constant Field Values

## Constructor Details

### PoolConfig

public PoolConfig(Properties props) throws NumberFormatException
Deprecated.

Throws:
  `NumberFormatException`

### PoolConfig

public PoolConfig() throws NumberFormatException
Deprecated.

Throws:
  `NumberFormatException`

## Method Details

### defaultNumHelperThreads

public static int defaultNumHelperThreads()
Deprecated.

### defaultPreferredTestQuery

public static String defaultPreferredTestQuery()
Deprecated.

### defaultFactoryClassLocation

public static String defaultFactoryClassLocation()
Deprecated.

### defaultMaxStatements

public static int defaultMaxStatements()
Deprecated.

### defaultMaxStatementsPerConnection

public static int defaultMaxStatementsPerConnection()
Deprecated.

### defaultInitialPoolSize

public static int defaultInitialPoolSize()
Deprecated.

### defaultMinPoolSize

public static int defaultMinPoolSize()
Deprecated.

### defaultMaxPoolSize

public static int defaultMaxPoolSize()
Deprecated.

### defaultIdleConnectionTestPeriod

public static int defaultIdleConnectionTestPeriod()
Deprecated.

### defaultMaxIdleTime

public static int defaultMaxIdleTime()
Deprecated.

### defaultPropertyCycle

public static int defaultPropertyCycle()
Deprecated.

### defaultCheckoutTimeout

public static int defaultCheckoutTimeout()
Deprecated.

### defaultAcquireIncrement

public static int defaultAcquireIncrement()
Deprecated.

### defaultAcquireRetryAttempts

public static int defaultAcquireRetryAttempts()
Deprecated.

### defaultAcquireRetryDelay

public static int defaultAcquireRetryDelay()
Deprecated.

### defaultBreakAfterAcquireFailure

public static boolean defaultBreakAfterAcquireFailure()
Deprecated.

### defaultConnectionTesterClassName

public static String defaultConnectionTesterClassName()
Deprecated.

### defaultAutomaticTestTable

public static String defaultAutomaticTestTable()
Deprecated.

### defaultTestConnectionOnCheckout

public static boolean defaultTestConnectionOnCheckout()
Deprecated.

### defaultTestConnectionOnCheckin

public static boolean defaultTestConnectionOnCheckin()
Deprecated.

### defaultAutoCommitOnClose

public static boolean defaultAutoCommitOnClose()
Deprecated.

### defaultForceIgnoreUnresolvedTransactions

public static boolean defaultForceIgnoreUnresolvedTransactions()
Deprecated.

### defaultUsesTraditionalReflectiveProxies

public static boolean defaultUsesTraditionalReflectiveProxies()
Deprecated.

### getNumHelperThreads

public int getNumHelperThreads()
Deprecated.

### getPreferredTestQuery

public String getPreferredTestQuery()
Deprecated.

### getFactoryClassLocation

public String getFactoryClassLocation()
Deprecated.

### getMaxStatements

public int getMaxStatements()
Deprecated.

### getMaxStatementsPerConnection

public int getMaxStatementsPerConnection()
Deprecated.

### getInitialPoolSize

public int getInitialPoolSize()
Deprecated.

### getMinPoolSize

public int getMinPoolSize()
Deprecated.

### getMaxPoolSize

public int getMaxPoolSize()
Deprecated.

### getIdleConnectionTestPeriod

public int getIdleConnectionTestPeriod()
Deprecated.

### getMaxIdleTime

public int getMaxIdleTime()
Deprecated.

### getPropertyCycle

public int getPropertyCycle()
Deprecated.

### getAcquireIncrement

public int getAcquireIncrement()
Deprecated.

### getCheckoutTimeout

public int getCheckoutTimeout()
Deprecated.

### getAcquireRetryAttempts

public int getAcquireRetryAttempts()
Deprecated.

### getAcquireRetryDelay

public int getAcquireRetryDelay()
Deprecated.

### isBreakAfterAcquireFailure

public boolean isBreakAfterAcquireFailure()
Deprecated.

### isUsesTraditionalReflectiveProxies

public boolean isUsesTraditionalReflectiveProxies()
Deprecated.

### getConnectionTesterClassName

public String getConnectionTesterClassName()
Deprecated.

### getAutomaticTestTable

public String getAutomaticTestTable()
Deprecated.

### getTestConnectionOnCheckout

public boolean getTestConnectionOnCheckout()
Deprecated.
use isTestConnectionOnCheckout

### isTestConnectionOnCheckout

public boolean isTestConnectionOnCheckout()
Deprecated.

### isTestConnectionOnCheckin

public boolean isTestConnectionOnCheckin()
Deprecated.

### isAutoCommitOnClose

public boolean isAutoCommitOnClose()
Deprecated.

### isForceIgnoreUnresolvedTransactions

public boolean isForceIgnoreUnresolvedTransactions()
Deprecated.

### setNumHelperThreads

public void setNumHelperThreads(int numHelperThreads)
Deprecated.

### setPreferredTestQuery

public void setPreferredTestQuery(String preferredTestQuery)
Deprecated.

### setFactoryClassLocation

public void setFactoryClassLocation(String factoryClassLocation)
Deprecated.

### setMaxStatements

public void setMaxStatements(int maxStatements)
Deprecated.

### setMaxStatementsPerConnection

public void setMaxStatementsPerConnection(int maxStatementsPerConnection)
Deprecated.

### setInitialPoolSize

public void setInitialPoolSize(int initialPoolSize)
Deprecated.

### setMinPoolSize

public void setMinPoolSize(int minPoolSize)
Deprecated.

### setMaxPoolSize

public void setMaxPoolSize(int maxPoolSize)
Deprecated.

### setIdleConnectionTestPeriod

public void setIdleConnectionTestPeriod(int idleConnectionTestPeriod)
Deprecated.

### setMaxIdleTime

public void setMaxIdleTime(int maxIdleTime)
Deprecated.

### setPropertyCycle

public void setPropertyCycle(int propertyCycle)
Deprecated.

### setCheckoutTimeout

public void setCheckoutTimeout(int checkoutTimeout)
Deprecated.

### setAcquireIncrement

public void setAcquireIncrement(int acquireIncrement)
Deprecated.

### setAcquireRetryAttempts

public void setAcquireRetryAttempts(int acquireRetryAttempts)
Deprecated.

### setAcquireRetryDelay

public void setAcquireRetryDelay(int acquireRetryDelay)
Deprecated.

### setConnectionTesterClassName

public void setConnectionTesterClassName(String connectionTesterClassName)
Deprecated.

### setAutomaticTestTable

public void setAutomaticTestTable(String automaticTestTable)
Deprecated.

### setBreakAfterAcquireFailure

public void setBreakAfterAcquireFailure(boolean breakAfterAcquireFailure)
Deprecated.

### setUsesTraditionalReflectiveProxies

public void setUsesTraditionalReflectiveProxies(boolean usesTraditionalReflectiveProxies)
Deprecated.

### setTestConnectionOnCheckout

public void setTestConnectionOnCheckout(boolean testConnectionOnCheckout)
Deprecated.

### setTestConnectionOnCheckin

public void setTestConnectionOnCheckin(boolean testConnectionOnCheckin)
Deprecated.

### setAutoCommitOnClose

public void setAutoCommitOnClose(boolean autoCommitOnClose)
Deprecated.

### setForceIgnoreUnresolvedTransactions

public void setForceIgnoreUnresolvedTransactions(boolean forceIgnoreUnresolvedTransactions)
Deprecated.