Thursday 20 May 2010

Cannot call commit when using distributed transactions.

While testing some BPEL Process we encountered the following error in the DB Adapter call:

Exception occured when binding was invoked. Exception occured during invocation of JCA binding: "JCA Binding execute of Reference operation 'SP_CreateCaseData' failed due to: DBWriteInteractionSpec Execute Failed Exception. unknown failed. Descriptor name: [unknown]. Caused by java.sql.SQLException: Cannot call commit when using distributed transactions. ". The invoked JCA adapter raised a resource exception. Please examine the above error message carefully to determine a resolution.


To resolve this, go to Deployments on the weblogic console and open DBAdapter. Go to Connection - Outbound Connection Pool where the jndi is configured to talk to the jdbc data source.
Expand the javax.resource.cci.ConnectionFactory and select the appropiate Connection. There we can see that the data source name is configured in the dataSourceName row while it should be configured in the xaDataSourceName row. This is because the datasource is defined as XA.

2 comments:

  1. On the other hand if you really intended your dataSource to be non-XA, please go back to your JDBC Data Source and have your JDBC DataSource Driver class name set to non-XA compatible one like oracle.jdbc.OracleDriver.

    ReplyDelete
  2. Thanks dude!!!! It worked for me and sinda(my colleague) :)

    ReplyDelete