If the configured amount of allowed open cursors in an Oracle database is exceeded, the following error message will be thrown:

java.sql.SQLException: ORA-01000: maximum open cursors exceeded
This can be due to the following possible causes:

  • Incorrect configuration of the JDBC pool regarding the prepared statement cache. Every prepared statement will use one open cursor in the Oracle database. The statement cache holds prepared statements on a connection basis. This means that the Oracle database will use up to (StatementCacheSize)x(MaxCapacity)open cursors for every configured pool. As open cursors will be used for other objects also (e.g., stored procedures or result sets), the number of open cursors needs to be configured high enough to hold all the statements in the statement cache. The setting for OPEN_CURSORS is per session/connection.

    For additional information on statement cache configuration, please see Monitoring JDBC Resources

getVendorConnection()is called and physical connection is automatically refreshed after each usage by the application (when RemoveInfectedConnections="true")

As this means that connection pooling loses its effect, i.e., every connection is closed and reopened after each usage, please consider carefully if the application code changes or destroys something on the physical connection that makes such a reopen necessary. If and only if this is not the case, set the property RemoveInfectedConnectionsto false.

More more details : http://middlewaretimes.blogspot.com/2014/08/investigating-ora-01000-maximum-open.html


0 Comments