This discussion is archived
2 Replies Latest reply: Feb 27, 2012 5:06 PM by user2363353 RSS

Oracle db connection reset error

user2363353 Newbie
Currently Being Moderated
Currently using toplink to manage the db connection and we see the following error in the logs file. Is there way to avoid exception being thrown?

Here is the stack trace:

Caused by: Portable(java.sql.SQLRecoverableException): IO Error: Connection reset
at oracle.jdbc.driver.T4CPreparedStatement.executeForRows(
at oracle.jdbc.driver.OracleStatement.executeMaybeDescribe(
at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(
at oracle.jdbc.driver.OraclePreparedStatement.executeInternal(
at oracle.jdbc.driver.OraclePreparedStatement.executeQuery(
at oracle.jdbc.driver.OraclePreparedStatementWrapper.executeQuery(
at org.eclipse.persistence.internal.databaseaccess.DatabaseAccessor.executeSelect(
at org.eclipse.persistence.internal.databaseaccess.DatabaseAccessor.basicExecuteCall(
at org.eclipse.persistence.internal.databaseaccess.DatabaseAccessor.executeCall(
at org.eclipse.persistence.internal.sessions.AbstractSession.basicExecuteCall(
at org.eclipse.persistence.sessions.server.ServerSession.executeCall(
at org.eclipse.persistence.sessions.server.ClientSession.executeCall(
at org.eclipse.persistence.internal.queries.DatasourceCallQueryMechanism.executeCall(
at org.eclipse.persistence.internal.queries.DatasourceCallQueryMechanism.executeCall(
at org.eclipse.persistence.internal.queries.DatasourceCallQueryMechanism.selectRowForDoesExist(

Any help is much appreciated.
  • 1. Re: Oracle db connection reset error
    JamesSutherland Pro
    Currently Being Moderated
    The issue is that your database connection has been lost somehow. This may be caused by a timeout in your database or firewall, or a database or network error.

    You can either try resolve the database/network issue, or workaround the issue.

    In TopLink by default when using a recent version of EclipseLink, dead connections should be automatically detected and reconnected. You will still get the error, but the connection will be dropped form the pool and a new connection used for the query. If you just want the error out of your log, then disable logging or disable exception logging.

    To avoid the issue entirely, you could disable connection pooling by setting your min pool size to 0, but this can adversely affect performance.

    You could also use a third party DataSource such as Oracle UCP, that provides additional dead connection resolution solutions.
  • 2. Re: Oracle db connection reset error
    user2363353 Newbie
    Currently Being Moderated
    Thanks for the response.

    It seems to match my analysis.


  • Correct Answers - 10 points
  • Helpful Answers - 5 points