Skip to Content
0
Former Member
Apr 15, 2005 at 12:54 PM

Oracle connection getting terminated!

124 Views

Hi,

We are creating an application that needs to connect to Oracle database. For this we created a datasource in the server and the application was making use of this datasource succesfully for few weeks. But now at times, the connection is getting terminated abruptly. When I try to execute the test sql statement, it throws me an error, which I'm adding here. Once I restart the service, it works fine for sometime before going down again. Can someone please help me to find a solution for this?

Thanks in advance !

Best Regards,

Nibu.

java.rmi.RemoteException: com.sap.engine.services.dbpool.exceptions.BaseRemoteException: SQL statement(s) cannot be executed over DataSource "HCLOracle". If you are using an Open SQL DataSource, you must register your tables using JDDI before you request them. Reason: com.sap.engine.services.dbpool.exceptions.BaseSQLException: ResourceException in method ConnectionFactoryImpl.getConnection(): com.sap.engine.services.connector.exceptions.BaseResourceException: Error in ResourceSet.addAndEnlist("com.sap.engine.services.connector.resource.impl.HandleWrapper@d6946[com.sap.engine.services.dbpool.cci.ConnectionHandle@de71fc](delisted:false) -> com.sap.engine.services.connector.resource.impl.MCEventHandler@7a9070 --> 72(locTrSupp:true)").

at com.sap.engine.services.dbpool.deploy.DataSourceManagerImpl.executeFromAppThread(DataSourceManagerImpl.java:1127)

at com.sap.engine.services.dbpool.deploy.DataSourceManagerImpl.executeInitStatements(DataSourceManagerImpl.java:507)

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)

at java.lang.reflect.Method.invoke(Method.java:324)

at com.sap.pj.jmx.introspect.DefaultMBeanInvoker.invoke(DefaultMBeanInvoker.java:58)

at com.sap.pj.jmx.mbeaninfo.AdditionalInfoProviderMBean.invoke(AdditionalInfoProviderMBean.java:289)

at com.sap.pj.jmx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:944)

at com.sap.pj.jmx.server.interceptor.MBeanServerWrapperInterceptor.invoke(MBeanServerWrapperInterceptor.java:288)

at com.sap.engine.services.jmx.CompletionInterceptor.invoke(CompletionInterceptor.java:400)

at com.sap.engine.services.jmx.RedirectInterceptor.invoke(RedirectInterceptor.java:340)

at com.sap.pj.jmx.server.interceptor.MBeanServerInterceptorChain.invoke(MBeanServerInterceptorChain.java:330)

at com.sap.engine.services.jmx.MBeanServerSecurityWrapper.invoke(MBeanServerSecurityWrapper.java:287)

at com.sap.engine.services.jmx.MBeanServerInvoker.invokeMbs(MBeanServerInvoker.java:157)

at com.sap.engine.services.jmx.ClusterInterceptor.invokeMbs(ClusterInterceptor.java:220)

at com.sap.engine.services.jmx.ClusterInterceptor.invoke(ClusterInterceptor.java:803)

at com.sap.engine.services.jmx.MBeanServerInterceptorInvoker.invokeMbs(MBeanServerInterceptorInvoker.java:102)

at com.sap.engine.services.jmx.connector.p4.P4ConnectorServerImpl.invokeMbs(P4ConnectorServerImpl.java:61)

at com.sap.engine.services.jmx.connector.p4.P4ConnectorServerImplp4_Skel.dispatch(P4ConnectorServerImplp4_Skel.java:64)

at com.sap.engine.services.rmi_p4.DispatchImpl._runInternal(DispatchImpl.java:291)

at com.sap.engine.services.rmi_p4.DispatchImpl._run(DispatchImpl.java:183)

at com.sap.engine.services.rmi_p4.server.P4SessionProcessor.request(P4SessionProcessor.java:119)

at com.sap.engine.core.service630.context.cluster.session.ApplicationSessionMessageListener.process(ApplicationSessionMessageListener.java:37)

at com.sap.engine.core.cluster.impl6.session.UnorderedChannel$MessageRunner.run(UnorderedChannel.java:71)

at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37)

at java.security.AccessController.doPrivileged(Native Method)

at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:94)

at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:162)

Caused by: com.sap.engine.services.dbpool.exceptions.BaseSQLException: ResourceException in method ConnectionFactoryImpl.getConnection(): com.sap.engine.services.connector.exceptions.BaseResourceException: Error in ResourceSet.addAndEnlist("com.sap.engine.services.connector.resource.impl.HandleWrapper@d6946[com.sap.engine.services.dbpool.cci.ConnectionHandle@de71fc](delisted:false) -> com.sap.engine.services.connector.resource.impl.MCEventHandler@7a9070 --> 72(locTrSupp:true)").

at com.sap.engine.services.dbpool.cci.ConnectionFactoryImpl.getConnection(ConnectionFactoryImpl.java:59)

at com.sap.engine.services.dbpool.deploy.DBInitializer.run(DBInitializer.java:62)

... 4 more

Caused by: com.sap.engine.services.connector.exceptions.BaseResourceException: Error in ResourceSet.addAndEnlist("com.sap.engine.services.connector.resource.impl.HandleWrapper@d6946[com.sap.engine.services.dbpool.cci.ConnectionHandle@de71fc](delisted:false) -> com.sap.engine.services.connector.resource.impl.MCEventHandler@7a9070 --> 72(locTrSupp:true)").

at com.sap.engine.services.connector.jca.ConnectionManagerImpl.allocateConnection(ConnectionManagerImpl.java:241)

at com.sap.engine.services.dbpool.cci.ConnectionFactoryImpl.getConnection(ConnectionFactoryImpl.java:51)

... 5 more

Caused by: com.sap.engine.services.ts.exceptions.BaseSystemException: Exception in LocalTransaction.begin.

at com.sap.engine.services.ts.jta.impl.TransactionImpl.enlistLocalResource(TransactionImpl.java:876)

at com.sap.engine.services.connector.resource.impl.ResourceSetImpl.addAndEnlist(ResourceSetImpl.java:260)

at com.sap.engine.services.connector.jca.ConnectionManagerImpl.allocateConnection(ConnectionManagerImpl.java:238)

... 6 more

Caused by: com.sap.engine.services.dbpool.exceptions.BaseResourceException: SQLException thrown by the physical connection: java.sql.SQLException: ORA-02396: exceeded maximum idle time, please connect again

at com.sap.engine.services.dbpool.spi.LocalTXManagedConnectionImpl.throwBaseResourceException(LocalTXManagedConnectionImpl.java:84)

at com.sap.engine.services.dbpool.spi.LocalTXManagedConnectionImpl.begin(LocalTXManagedConnectionImpl.java:396)

at com.sap.engine.services.ts.jta.impl.TransactionImpl.enlistLocalResource(TransactionImpl.java:866)

... 8 more

Caused by: java.sql.SQLException: ORA-02396: exceeded maximum idle time, please connect again

at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:134)

at oracle.jdbc.ttc7.TTIoer.processError(TTIoer.java:289)

at oracle.jdbc.ttc7.Ocommoncall.receive(Ocommoncall.java:138)

at oracle.jdbc.ttc7.TTC7Protocol.setAutoCommit(TTC7Protocol.java:538)

at oracle.jdbc.driver.OracleConnection.setAutoCommit(OracleConnection.java:1223)

at com.sap.engine.services.dbpool.spi.LocalTXManagedConnectionImpl.begin(LocalTXManagedConnectionImpl.java:393)

... 9 more

at com.sap.engine.services.dbpool.exceptions.BaseRemoteException.writeReplace(BaseRemoteException.java:176)

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)

at java.lang.reflect.Method.invoke(Method.java:324)

at java.io.ObjectStreamClass.invokeWriteReplace(ObjectStreamClass.java:896)

at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1011)

at java.io.ObjectOutputStream.defaultWriteFields(ObjectOutputStream.java:1332)

at java.io.ObjectOutputStream.defaultWriteObject(ObjectOutputStream.java:367)

at javax.management.MBeanException.writeObject(MBeanException.java:126)

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)

at java.lang.reflect.Method.invoke(Method.java:324)

at java.io.ObjectStreamClass.invokeWriteObject(ObjectStreamClass.java:809)

at java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1296)

at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1247)

at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1052)

at java.io.ObjectOutputStream.defaultWriteFields(ObjectOutputStream.java:1332)

at java.io.ObjectOutputStream.defaultWriteObject(ObjectOutputStream.java:367)

at com.sap.exception.BaseExceptionInfo.writeObject(BaseExceptionInfo.java:964)

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)

at java.lang.reflect.Method.invoke(Method.java:324)

at java.io.ObjectStreamClass.invokeWriteObject(ObjectStreamClass.java:809)

at java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1296)

at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1247)

at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1052)

at java.io.ObjectOutputStream.defaultWriteFields(ObjectOutputStream.java:1332)

at java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1304)

at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1247)

at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1052)

at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:278)

at com.sap.engine.services.jmx.ResponseMessage.writeBody(ResponseMessage.java:168)

at com.sap.engine.services.jmx.Message.writeMsg(Message.java:257)

at com.sap.engine.services.jmx.Message.getMsg(Message.java:453)

at com.sap.engine.services.jmx.Message.writeExternal(Message.java:505)

at java.io.ObjectOutputStream.writeExternalData(ObjectOutputStream.java:1267)

at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1245)

at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1052)

at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:278)

at com.sap.engine.services.jmx.connector.p4.P4ConnectorServerImplp4_Skel.dispatch(P4ConnectorServerImplp4_Skel.java:66)

at com.sap.engine.services.rmi_p4.DispatchImpl._runInternal(DispatchImpl.java:291)

at com.sap.engine.services.rmi_p4.DispatchImpl._run(DispatchImpl.java:183)

at com.sap.engine.services.rmi_p4.server.P4SessionProcessor.request(P4SessionProcessor.java:119)

at com.sap.engine.core.service630.context.cluster.session.ApplicationSessionMessageListener.process(ApplicationSessionMessageListener.java:37)

at com.sap.engine.core.cluster.impl6.session.UnorderedChannel$MessageRunner.run(UnorderedChannel.java:71)

at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37)

at java.security.AccessController.doPrivileged(Native Method)

at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:94)

at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:162)