Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Two phase commit problem

2 views
Skip to first unread message

jeff mutonho

unread,
Aug 15, 2003, 12:36:51 PM8/15/03
to
Hi
I have a method which , just before returning , uses two entity beans
to populate two oracle database tables.The method looks like this:

public void addServices(long id , String version.....){

//do stuff here
//.....
geoLocalPopulator.insertGeoLocal(id);
siteService.create();
}
geoLocalPopulator.insertGeoLocal(id) uses an entity bean to populate a
table on an oracle database.
siteService.create() also uses another (different) entity bean to
populate another table on the same oracle database.Both datasources are
defined as oracle.jdbc.xa.client.OracleXADataSource.I'm getting the
following exception when I try to insert data into the datasources.

java.sql.SQLException: ORA-00603: ORACLE server session terminated by
fatal error
ORA-02051: another session in same transaction failed
ORA-02051: another session in same transaction failed

at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:168)
at oracle.jdbc.ttc7.TTIoer.processError(TTIoer.java:208)
at oracle.jdbc.ttc7.Oall7.receive(Oall7.java:543)
at oracle.jdbc.ttc7.TTC7Protocol.doOall7(TTC7Protocol.java:1405)
at oracle.jdbc.ttc7.TTC7Protocol.parseExecuteFetch(TTC7Protocol.java:822)
at
oracle.jdbc.driver.OracleStatement.executeNonQuery(OracleStatement.java:1446)
at
oracle.jdbc.driver.OracleStatement.doExecuteOther(OracleStatement.java:1371)
at
oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1900)
at
oracle.jdbc.driver.OraclePreparedStatement.executeUpdate(OraclePreparedStatement.java:363)
at
oracle.jdbc.driver.OraclePreparedStatement.execute(OraclePreparedStatement.java:407)
at oracle.jdbc.xa.client.OracleXAResource.end(OracleXAResource.java:265)
at com.ibm.ejs.jts.jta.XARminst.endAssociation(XARminst.java:365)
at
com.ibm.ejs.jts.jta.portable.JTAXAResourceImpl.completionPreinvoke(JTAXAResourceImpl.java:707)
at
com.ibm.ejs.jts.jta.portable.JTAXAResourceImpl.prepare(JTAXAResourceImpl.java:414)
at
com.ibm.ejs.jts.jts.ResourceVector.deliverPrepare(ResourceVector.java:209)
at
com.ibm.ejs.jts.jts.ResourceVector.beforePrepare(ResourceVector.java:185)
at
com.ibm.ejs.jts.tran.EventCallback.executeCallback(EventCallback.java:161)
at
com.ibm.ejs.jts.tran.EventCallback.executeCallbackTree(EventCallback.java:132)
at
com.ibm.ejs.jts.tran.EventCallback.executeCallbackTree(EventCallback.java:123)
at
com.ibm.ejs.jts.tran.EventPrepare.ExecuteBeforePrepareCallbacks(EventPrepare.java:302)
at
com.ibm.ejs.jts.tran.EventPrepare.event_LocalPrepareWork(EventPrepare.java:277)
at
com.ibm.ejs.jts.tran.EventPrepare.event_BecomeCoordinator(EventPrepare.java:960)
at
com.ibm.ejs.jts.tran.EventControl.event_EndTopLevel(EventControl.java:295)
at com.ibm.ejs.jts.tran.TrecInterface.end(TrecInterface.java:88)
at com.ibm.ejs.jts.jts.TerminatorImpl.commit(TerminatorImpl.java:89)
at com.ibm.ejs.jts.jts.CurrentImpl.commit(CurrentImpl.java:200)
at com.ibm.ejs.jts.jts.CurrentSet.commit(CurrentSet.java:256)
at com.ibm.ejs.csi.TranStrategy.commit(TranStrategy.java:190)
at com.ibm.ejs.csi.TranStrategy.postInvoke(TranStrategy.java:67)
at
com.ibm.ejs.csi.TransactionControlImpl.postInvoke(TransactionControlImpl.java:443)
at com.ibm.ejs.container.EJSContainer.postInvoke(EJSContainer.java:1840)
at
net.msl.stackdates.session.message.EJSRemoteStatelessMessageService_d9901358.addService(EJSRemoteStatelessMessageService_d9901358.java:155)
at
net.msl.stackdates.session.message._MessageService_Stub.addService(_MessageService_Stub.java:417)
at
net.msl.stackdates.session.message.queuehelper.ServiceCommandHandler.addService(ServiceCommandHandler.java:48)
at
net.msl.stackdates.session.message.queuehelper.ServiceCommandHandler.handle(ServiceCommandHandler.java:86)
at
net.msl.stackdates.session.message.queuehelper.MessageHandler.handle(MessageHandler.java:56)
at
net.msl.stackdates.session.message.queuehelper.QListenerThread.run(QListenerThread.java:90)

Whe I comment out geoLocalPopulator.insertGeoLocal(id);
I don't get an exception and siteService.create(); succeeds in inserting
data in the table.Commenting out only siteService.create(); , the
exception is thrown.

jeff mutonho

vtoledoc

unread,
Sep 5, 2003, 8:54:36 PM9/5/03
to
got the same problem, could you please indicate me how you resolve it?
thanks a lot

Jeff Mutonho

unread,
Sep 8, 2003, 9:27:30 AM9/8/03
to
vtoledoc <victor...@neoris.com> wrote in message news:<593641809.1062809677152.JavaMail.wasadmin@swg3ws006>...

> got the same problem, could you please indicate me how you resolve it?
> thanks a lot

I'm still looking for a solution.I think someone from IBM must make an
effort to help.This is a very frustrating problem
:((

jeff mutonho

0 new messages