Use this page to create a connection pool for a Version 4.0 data source.
To view this administrative console page, click Resources > JDBC Providers > JDBC_provider > Data Sources (Version 4) > data_source > Connection Pool.
Configuration tab
Specifies the level to which this resource definition is visible -- the cell, node, or server level.
Resources such as JDBC providers, namespace bindings, or shared libraries can be defined at multiple scopes, with resources defined at more specific scopes overriding duplicates which are defined at more general scopes.
When resources are created, they are always created into the current scope selected in the panel. To view resources in other scopes, specify a different node or server in the scope selection form.
Data type | String |
Specifies the minimum number of connections to maintain in the pool.
The minimum pool size can affect the performance of an application. Smaller pools require less overhead when the demand is low because fewer connections are held open to the database. When the demand is high, the first applications experience a slow response because new connections are created if all others in the pool are in use.
Data type | Integer |
Default | 1 |
Range | Any non-negative integer. |
Specifies the maximum number of connections to maintain in the pool.
If the maximum number of connections is reached and all connections are in use, additional requests for a connection wait up to the number of seconds specified as the connection timeout. The maximum pool size can affect the performance of an application. Larger pools require more overhead when demand is high because there are more connections open to the database at peak demand. These connections persist until idled out of the pool. If the maximum value is smaller, longer wait times or possible connection timeout errors during peak times can occur. Ensure that the database can support the maximum number of connections in the application server, in addition to any load that it has outside of the application server.
Data type | Integer |
Default | 10 |
Range | Any positive integer |
Specifies the maximum number of seconds an application waits for a connection from the pool before timing out and issuing a ConnectionWaitTimeout exception to the application.
Setting this value to 0 disables the connection timeout.
Data type | Integer |
Units | Seconds |
Default | 180 |
Range | Any non-negative integer |
Specifies the maximum number of seconds that an idle (unallocated) connection can remain in the pool before being removed to free resources.
Connections need to idle out of the pool because keeping connections open to the database can cause database memory problems. However, not all connections are idled out of the pool, even if they are older than the Idle Timeout setting. A connection is not idled if removing the connection would cause the pool to shrink below its minimum size. Setting this value to 0 disables the idle timeout.
Data type | Integer |
Units | Seconds |
Default | 1800 |
Range | Any non-negative integer |
Specifies the maximum number of seconds that an application can hold a connection without using it before the connection returns to the pool
If there is no activity on an allocated connection for longer than the Orphan Timeout setting, the connection is marked for orphaning. After another Orphan Timeout number of seconds, if the connection still has no activity, the connection returns to the pool. If the application tries to use the connection again, it is issued a stale connection exception. Connections that are enlisted in a transaction are not orphaned. Setting this value to 0 disables the orphan timeout.
Data type | Integer |
Units | Seconds |
Default | 1800 |
Range | Any non-negative integer |
Specifies the number of cached prepared statements to keep per connection.
The largest value you would need to set your cache size to if you do not want any cache discards is determined as follows: for each application that uses this data source on a particular server, add up the number of unique prepared statements (as determined by the sql string, concurrency, and the scroll type). This is the maximum number of possible prepared statements that can be cached on a given connection over the life of the server. Setting the cache size to this value means you never have cache discards. This provides better performance. However, because of potential resource limitations, this might not always be possible.
Data type | Integer |
Default | 10 |
Range | Any non-negative integer |
Specifies whether or not the connection pooling software automatically closes connections from this data source at the end of a transaction.
The default is false, which indicates that when a transaction completes, WebSphere Application Server closes the connection and returns it to the pool. Any use of the connection after the transaction has ended results in a stale connection exception because the connection is closed and has returned to the pool. This mechanism ensures that connections are not held indefinitely by the application. If the value is set to true, the connection is not returned to the pool at the end of a transaction. In this case, the application must return the connection to the pool by calling close(). If the application does not close the connection, the pool can run out of connections for other applications to use.
Data type | Check box |
Default | False (clear) |
Related concepts
JDBC providers
Data sources
Connection pooling
Related tasks
Creating and configuring a data source using the administrative console
Configuring connection factories for resource adapters within applications
Configuring J2EE Connector connection factories in the administrative
console