Monday, September 17, 2012

A Oracle Consultant suggested to set the property
for every ConnectionPool

What is this?


Another useful property is:

"Set TimeToLiveTimeout to m seconds
Set PropertyCheckInterval to n seconds

if the network call is blocked, then just setting the TimeToLive timeout alone won't work. In that case, an additional step is needed -- setting the JDBC driver connection properties as follows:

for the Thin driver:
for the OCI driver: sqlnet.outbound_connection_timeout

There is a Oracle KB doc:
"How to Ensure that JDBC Queries are Always Timed Out [ID 559564.1]"

For more info on the TimeToLiveTimeout and PropertyCheckInterval :


set a timeout on Socket level for the jdbc thin driver: (in ms)

in reality: for jdbc versions < oracle.jdbc.ReadTimeout for jdbc versions >=


"In some deployments of Oracle RAC, you may need to set parameters in addition to the out of the box configuration of a data source in an Oracle RAC configuration. The additional parameters are:

Set oracle.jdbc.ReadTimeout=300000 (300000 milliseconds) for each data source."


The Oracle Consultant says:
"I would set the read and connect timeouts to slightly longer than the stuck thread time setting.
This ensures you get stuck thread warnings but the thread is released soon after "


Related Oracle KB docs:

ORACLE.NET.READ_TIMEOUT Property Does Not Work On 11g JDBC Driver [ID 1341966.1]

WebLogic Server: Intermittent Stuck Threads Caused Due to the 11.1.x Oracle JDBC Thin Driver [ID 1083794.1] (this one seems to be pretty old)

How to Ensure that JDBC Queries are Always Timed Out [ID 559564.1], the suggest using

  • for the Thin driver:
  • for the OCI driver:  sqlnet.outbound_connection_timeout

No comments: