We have been facing an issue, where a simple ejb-ql query runs out of transaction time, if same(WL generated SQL version of ejb-ql) is run from SQL command prompt, it takes very less time than the configured JTA time(execute less than 5% time of JTA).
Erros: Few time the error thrown is:
javax.ejb.FinderException: Exception in 'finderMethodName' while using result set: 'weblogic.jdbc.wrapper.ResultSet_oracle_jdbc_driver_OracleResultSetImpl@9c18f' java.sql.SQLException: Unexpected exception while enlisting XAConnection java.sql.SQLException: Transaction rolled back: Transaction timed out after 301 seconds
Note - JTA is configured to 300 seconds
Most of the time the error thrown is:
javax.ejb.FinderException: Exception in 'finderMethodName' while using result set: 'weblogic.jdbc.wrapper.ResultSet_oracle_jdbc_driver_OracleResultSetImpl@a5af' java.sql.SQLException: Result set already closed
You should increase the timeout in the container.
Service Configurations -> Other Services
Click JTA Configuration(Under Other Services)
Then you will see the Timeout Seconds on the top of the page.