[jboss-svn-commits] JBL Code SVN: r30454 - labs/jbosstm/workspace/whitingjr/trunk/performance/src/main/resources/META-INF.
jboss-svn-commits at lists.jboss.org
jboss-svn-commits at lists.jboss.org
Thu Dec 3 11:58:22 EST 2009
Author: whitingjr
Date: 2009-12-03 11:58:22 -0500 (Thu, 03 Dec 2009)
New Revision: 30454
Modified:
labs/jbosstm/workspace/whitingjr/trunk/performance/src/main/resources/META-INF/persistence.xml
Log:
Added second resource to persistence configuration.
Modified: labs/jbosstm/workspace/whitingjr/trunk/performance/src/main/resources/META-INF/persistence.xml
===================================================================
--- labs/jbosstm/workspace/whitingjr/trunk/performance/src/main/resources/META-INF/persistence.xml 2009-12-03 16:57:35 UTC (rev 30453)
+++ labs/jbosstm/workspace/whitingjr/trunk/performance/src/main/resources/META-INF/persistence.xml 2009-12-03 16:58:22 UTC (rev 30454)
@@ -1,3 +1,4 @@
+<?xml version="1.0" encoding="UTF-8" ?>
<persistence 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
@@ -4,12 +5,12 @@
http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd"
version="1.0">
- <persistence-unit name="caveatemptor">
+ <persistence-unit name="caveatemptorA">
<!-- A managed datasource provided by the application server, in this
case the microcontainer, see caveatemptor-beans.xml definition.
-->
- <jta-data-source>java:/caveatemptorTestingDatasource</jta-data-source>
+ <jta-data-source>java:/caveatemptorTestingDatasourceA</jta-data-source>
<!-- The path to scan for entity classes, different than the root of this file
<jar-file>file:/home/work/local/hibernate/jpwh/caveatemptor.jpa/build/classes</jar-file>
@@ -19,6 +20,46 @@
<!-- Only scan and detect annotated entities -->
<property name="hibernate.archive.autodetection" value="class"/>
+ <!-- SQL stdout logging
+ -->
+ <property name="hibernate.show_sql" value="false"/>
+ <property name="hibernate.format_sql" value="true"/>
+ <property name="use_sql_comments" value="false"/>
+ <property name="org.hibernate.SQL" value="true"/>
+
+ <property name="hibernate.dialect"
+ value="${db-vendor-hibernate.dialect}"/>
+
+ <!-- Put the EntityManagerFactory into JNDI so we can use it manually in tests -->
+ <property name="jboss.entity.manager.factory.jndi.name"
+ value="java:/EntityManagerFactories/caveatEmptorEMF_A"/>
+
+ <!-- Create the database schema when this test.persistence unit is deployed, drop
+ it (clean the database) when it is undeployed
+ -->
+ <property name="hibernate.hbm2ddl.auto" value="create-drop"/>
+
+ <property name="hibernate.generate_statistics" value="false"/>
+
+ <property name="hibernate.session_factory_name" value="java:/persistence/HibernateSessionFactoryA"/>
+ </properties>
+ </persistence-unit>
+
+ <persistence-unit name="caveatemptorB">
+
+ <!-- A managed datasource provided by the application server, in this
+ case the microcontainer, see caveatemptor-beans.xml definition.
+ -->
+ <jta-data-source>java:/caveatemptorTestingDatasourceB</jta-data-source>
+
+ <!-- The path to scan for entity classes, different than the root of this file
+ <jar-file>file:/home/work/local/hibernate/jpwh/caveatemptor.jpa/build/classes</jar-file>
+ -->
+
+ <properties>
+ <!-- Only scan and detect annotated entities -->
+ <property name="hibernate.archive.autodetection" value="class"/>
+
<!-- Only scan and detect hbm.xml files
<property name="hibernate.archive.autodetection" value="hbm"/>
-->
@@ -35,7 +76,7 @@
<!-- Put the EntityManagerFactory into JNDI so we can use it manually in tests -->
<property name="jboss.entity.manager.factory.jndi.name"
- value="java:/EntityManagerFactories/caveatEmptorEMF"/>
+ value="java:/EntityManagerFactories/caveatEmptorEMF_B"/>
<!-- Create the database schema when this test.persistence unit is deployed, drop
it (clean the database) when it is undeployed
@@ -44,8 +85,8 @@
<property name="hibernate.generate_statistics" value="false"/>
- <property name="hibernate.session_factory_name" value="java:/persistence/HibernateSessionFactory"/>
+ <property name="hibernate.session_factory_name" value="java:/persistence/HibernateSessionFactoryB"/>
</properties>
</persistence-unit>
-</persistence>
\ No newline at end of file
+</persistence>
More information about the jboss-svn-commits
mailing list