Permalink
Browse files

Modified student example to use a JTA DS

  • Loading branch information...
1 parent fb782ea commit 8accd932e06fb0a14c2e2e295f5fab14535cfbd5 Gul Onural committed Mar 13, 2013
Showing with 6 additions and 6 deletions.
  1. +6 −6 student/student.model/src/main/resources/META-INF/persistence.xml
@@ -2,16 +2,16 @@
<persistence version="2.0"
xmlns="http://java.sun.com/xml/ns/persistence" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_2_0.xsd">
- <persistence-unit name="jpars_example_student"
- transaction-type="RESOURCE_LOCAL">
+ <persistence-unit name="jpars_example_student" transaction-type="JTA">
<provider>org.eclipse.persistence.jpa.PersistenceProvider</provider>
+ <jta-data-source>jdbc/JPARSStudentDS</jta-data-source>
<class>eclipselink.example.jpars.student.model.Student</class>
<class>eclipselink.example.jpars.student.model.Course</class>
- <exclude-unlisted-classes />
+ <exclude-unlisted-classes/>
<properties>
- <property name="javax.persistence.nonJtaDataSource" value="jdbc/JPARSStudentDS" />
- <property name="eclipselink.logging.level" value="FINEST" />
- <property name="eclipselink.logging.parameters" value="true" />
+ <property name="eclipselink.logging.level" value="FINEST"/>
+ <property name="eclipselink.logging.parameters" value="true"/>
+ <property name="eclipselink.ddl-generation" value="drop-and-create-tables"/>
</properties>
</persistence-unit>
</persistence>

0 comments on commit 8accd93

Please sign in to comment.