vendredi 10 avril 2015

Spring application Oracle sql state null error code 17002

I have a Spring 2.5.6 application using Hibernate 3.2 which is connecting to a Oracle 10.2G database. Everything is working fine except some random issues during a nighttime scheduled massive update operation. This task perform ~20k/40k updates on database and sometimes(not always) it stops giving the following error:



SQL state [null]; error code [17002]; Io exception: Connection reset; nested exception is java.sql.SQLException: Io exception: Connection reset - java.sql.SQLException: Io exception: Connection reset
2015-04-09 19:36:40,479 ERROR - Could not toggle autocommit
java.sql.SQLException: Closed Connection
at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:125)
at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:162)
at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:227)
at oracle.jdbc.driver.PhysicalConnection.setAutoCommit(PhysicalConnection.java:893)
at com.mchange.v2.c3p0.impl.NewProxyConnection.setAutoCommit(NewProxyConnection.java:881)
at org.hibernate.transaction.JDBCTransaction.toggleAutoCommit(JDBCTransaction.java:194)
at org.hibernate.transaction.JDBCTransaction.rollbackAndResetAutoCommit(JDBCTransaction.java:186)
at org.hibernate.transaction.JDBCTransaction.rollback(JDBCTransaction.java:162)
at org.springframework.orm.hibernate3.HibernateTransactionManager.doRollback(HibernateTransactionManager.java:674)


and this is my context.xml:



<Context path="/MyApp" docBase="MyApp"
debug="5" reloadable="false" crossContext="true">

<Resource auth="Container" description="DB Connection" driverClass="oracle.jdbc.OracleDriver" maxPoolSize="150" minPoolSize="10"
maxIdleTimeExcessConnections="240"
idleConnectionTestPeriod="3000" preferredTestQuery="select 1"
acquireIncrement="1" name="jdbc/MyApp" user="thisisnottherealuser" password="thisisnottherealpassword" factory="org.apache.naming.factory.BeanFactory" type="com.mchange.v2.c3p0.ComboPooledDataSource"
jdbcUrl="jdbc:oracle:thin:@ipaddress:1521:MYAPP" />

<Resource auth="Container" description="DB Connection" driverClass="oracle.jdbc.OracleDriver" maxPoolSize="150" minPoolSize="10"
maxIdleTimeExcessConnections="240"
idleConnectionTestPeriod="300" preferredTestQuery="select 1"
acquireIncrement="1" name="jdbc/MYAPP_TMP" user="anotheruser" password="anotherpassword" factory="org.apache.naming.factory.BeanFactory" type="com.mchange.v2.c3p0.ComboPooledDataSource"
jdbcUrl="jdbc:oracle:thin:@ipaddress:1521:MYAPP" />

</Context>


I can't figure out what's triggering the issue because we've done some network checks and nothing seems to give problems.


Does anyone could help me finding a solution please?


Thanks in advance.


Aucun commentaire:

Enregistrer un commentaire