views:

70

answers:

1

Hello,

Is it possible to set the Oracle connection cache to restart cached connections after a period of time?

A: 

You can use the new Universal Connection Pool. The class oracle.ucp.jdbc.PoolDataSource has apropriate methods.

e.g.

void setTimeToLiveConnectionTimeout(int timeToLiveConnectionTimeout)
                                    throws java.sql.SQLException

see javadoc at: http://download.oracle.com/docs/cd/B28359_01/java.111/e11990/oracle/ucp/jdbc/PoolDataSource.html

Oliver Michels
This is exactly what I needed, thanks a ton.
Dario