Atomikos Forum

Configure Atomikos for JavaSE with Eclipselink

I want to use Atomikos with a simple JavaSE application, which uses EclipseLink 2.5.2.

Currently the RESOURCE_LOCAL type is used, but since some common classes should be used from JavaSE and JavaEE, it would be easier to only have JTA.

I changed the transaction type in the persistence.xml
<persistence-unit name="TestPU" transaction-type="JTA">

I also added the Maven dependencies with version 3.9.3
- transactions
- transactions-api
- transactions-jta
- transactions-eclipselink

When I start my application now, I get the message that a jtaDataSource is missing:
PersistenceUnitInfo TestPU has transactionType JTA, but does not have a jtaDataSource defined.

So I guess I have to define a data source
<jta-data-source>???</jta-data-source>

Does anyone know, which class name or value I have to specify there and what else I need to do, to get my local JavaSE application running with Atmoikos?
Simon Narkprasert Send private email
Friday, March 27, 2015
 
 
Hi,

eclipselink requires jta-data-source when transaction-type="JTA" is configured.

as you can find in example : http://www.atomikos.com/Documentation/ExampleApplications

We use XBean Spring JNDI https://cwiki.apache.org/confluence/display/SM/JNDI+configuration

to "mock" JNDI Context Factory under Spring/JSE environment.
Pascal Leclercq Send private email
Monday, March 30, 2015
 
 

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics