Loading

MuleSoft Anypoint Connector Error "ORA-01000: maximum open cursors exceeded"

게시 일자: Mar 25, 2026
솔루션
When using Oracle Database with Mule Database connector, "ORA-01000, the maximum-open-cursors error" is a commonly seen error.
 
Why would this error happen?
 
In terms of JDBC, each statement(including preparedstatement), resultset or connection uses an open cursor on Database end, and they(statement, resultset and connection) need to be closed explicitly to release the open cursor. 
 
If the application uses more open cursors then the limit set on Database end, this error is seen. Reducing client side JDBC threads number or increasing open cursor limit on database side will help to solve this problem in normal usage.
 
However, after a flow finishes, if there are still open cursors not released on Oracle database end, it's a leaking on open cursors. Increase open cursors limit on Database end won't help in this case. 
 
Known issues
 
Yes, there are both Mule known issue and Oracle known issues. 
 
Mule known issue
 
SE-2959, SQL statement is not closed which is causing open cursor leaks. This has been fixed in ESB 3.8.0, ESB 3.6.4, ESB 3.7.4, ESB 3.5.5. If you see this problem prior to these versions, please raise a support ticket with MuleSoft for a patch.
 
Oracle known issue:

Below are the list of issues that are reported in 12.1.x.x version of JDBC driver and got fixed in 12.2.0.1 version of the driver
Bug NumberFix VersionDescription
1586177512.2.0.1ORA-1000 cursor leak from some V$ / X$ table accesses
1624525112.2.0.1Cursor leak during DBMS_CDC_SUBSCRIBE.extend_window
2350880112.2.0.1Open cursors leaked from SQL using the XMLTYPE.getblobval() function
2026268412.2.0.1ORA-1000 reported from MMON (even with 14392595 fix)
1963248012.2.0.1Cursor leak / ORA-1000 from OracleDataMetaData.getTables() [most commonly impacted issue]
1795795912.2.0.1If ORA-1000 occurs in a Text query then recursive cursors are not closed - next query also gets ORA-1000
1439259512.2.0.1MMON may signal ORA-1000
If you can replicate the problem with a simple Java JDBC client, without Mule, it's likely an Oracle issue. In this case, please raise a support ticket with Oracle to get further help. 
 
Two standalone java samples are attached, which can be used to verify the issue without Mule: 
 
- sampleC3P0Project.zip : a maven project which uses C3P0 connection pool to test SQL queries
- TestOracleOpenCursors.java : a java class which uses pure JDBC to test SQL queries
 
When running the TestOracleOpenCursors.java class, once you saw the line in the standard output
"sleep for 5 minutes, so that connections in the pool are still maintained, it's time to check on Database end to see the current open cursors"
 
And if at this stage, the cursor usage is not reduced, then it is proof that the cursor is still being leaked from Oracle perspective.
 

Attachments

TestOracleOpenCursors.java
sampleC3P0Project.zip

Knowledge 기사 번호

001118725

 
로드 중
Salesforce Help | Article