Seam SVN: r9646 - trunk/examples/jee5/booking/resources/META-INF.
by seam-commits@lists.jboss.org
Author: dan.j.allen
Date: 2008-11-25 18:18:34 -0500 (Tue, 25 Nov 2008)
New Revision: 9646
Modified:
trunk/examples/jee5/booking/resources/META-INF/persistence.xml
Log:
don't need to specify transaction manager lookup when container is starting PU
Modified: trunk/examples/jee5/booking/resources/META-INF/persistence.xml
===================================================================
--- trunk/examples/jee5/booking/resources/META-INF/persistence.xml 2008-11-25 23:15:42 UTC (rev 9645)
+++ trunk/examples/jee5/booking/resources/META-INF/persistence.xml 2008-11-25 23:18:34 UTC (rev 9646)
@@ -5,30 +5,20 @@
version="1.0">
<persistence-unit name="bookingDatabase">
<provider>org.hibernate.ejb.HibernatePersistence</provider>
+ <!-- Change to java:/DefaultDS when deploying to JBoss AS 5 -->
<jta-data-source>jdbc/__default</jta-data-source>
<properties>
- <!-- The following two properties are for GlassFish -->
- <property name="hibernate.dialect"
- value="org.hibernate.dialect.DerbyDialect"/>
- <property name="hibernate.transaction.manager_lookup_class"
- value="org.hibernate.transaction.SunONETransactionManagerLookup"/>
-
-
- <!-- The following three properties are OC4J -->
- <!--
- <property name="hibernate.dialect"
- value="org.hibernate.dialect.HSQLDialect"/>
- <property name="hibernate.query.factory_class"
- value="org.hibernate.hql.classic.ClassicQueryTranslatorFactory"/>
- <property name="hibernate.transaction.manager_lookup_class"
- value="org.hibernate.transaction.OrionTransactionManagerLookup"/>
- -->
-
<property name="hibernate.hbm2ddl.auto" value="create-drop"/>
<property name="hibernate.show_sql" value="true"/>
<property name="hibernate.transaction.flush_before_completion" value="true"/>
- <property name="hibernate.cache.provider_class"
- value="org.hibernate.cache.HashtableCacheProvider"/>
+ <property name="hibernate.cache.provider_class" value="org.hibernate.cache.HashtableCacheProvider"/>
+ <!-- We don't need to specify a transaction manager lookup class for Hibernate
+ when the Java EE container loads the persistence unit (it gets inherited) -->
+
+ <!-- The following property is needed for OC4J -->
+ <!--
+ <property name="hibernate.query.factory_class" value="org.hibernate.hql.classic.ClassicQueryTranslatorFactory"/>
+ -->
</properties>
</persistence-unit>
</persistence>
15 years, 12 months
Seam SVN: r9645 - in trunk/examples: hibernate/view/css and 4 other directories.
by seam-commits@lists.jboss.org
Author: dan.j.allen
Date: 2008-11-25 18:15:42 -0500 (Tue, 25 Nov 2008)
New Revision: 9645
Modified:
trunk/examples/groovybooking/view/css/screen.css
trunk/examples/hibernate/view/css/screen.css
trunk/examples/jee5/booking/view/css/screen.css
trunk/examples/jpa/view/css/screen.css
trunk/examples/nestedbooking/view/css/screen.css
trunk/examples/spring/view/css/screen.css
Log:
fix button size problem
Modified: trunk/examples/groovybooking/view/css/screen.css
===================================================================
--- trunk/examples/groovybooking/view/css/screen.css 2008-11-25 23:12:19 UTC (rev 9644)
+++ trunk/examples/groovybooking/view/css/screen.css 2008-11-25 23:15:42 UTC (rev 9645)
@@ -267,6 +267,6 @@
#pgHome #content {
margin-top: 183px;
}
-#pgHome input[type="submit"] {
+#pgHome #sidebar input[type="submit"] {
height: 30px;
}
Modified: trunk/examples/hibernate/view/css/screen.css
===================================================================
--- trunk/examples/hibernate/view/css/screen.css 2008-11-25 23:12:19 UTC (rev 9644)
+++ trunk/examples/hibernate/view/css/screen.css 2008-11-25 23:15:42 UTC (rev 9645)
@@ -267,6 +267,6 @@
#pgHome #content {
margin-top: 183px;
}
-#pgHome input[type="submit"] {
+#pgHome #sidebar input[type="submit"] {
height: 30px;
}
Modified: trunk/examples/jee5/booking/view/css/screen.css
===================================================================
--- trunk/examples/jee5/booking/view/css/screen.css 2008-11-25 23:12:19 UTC (rev 9644)
+++ trunk/examples/jee5/booking/view/css/screen.css 2008-11-25 23:15:42 UTC (rev 9645)
@@ -267,6 +267,6 @@
#pgHome #content {
margin-top: 183px;
}
-#pgHome input[type="submit"] {
+#pgHome #sidebar input[type="submit"] {
height: 30px;
}
Modified: trunk/examples/jpa/view/css/screen.css
===================================================================
--- trunk/examples/jpa/view/css/screen.css 2008-11-25 23:12:19 UTC (rev 9644)
+++ trunk/examples/jpa/view/css/screen.css 2008-11-25 23:15:42 UTC (rev 9645)
@@ -267,6 +267,6 @@
#pgHome #content {
margin-top: 183px;
}
-#pgHome input[type="submit"] {
+#pgHome #sidebar input[type="submit"] {
height: 30px;
}
Modified: trunk/examples/nestedbooking/view/css/screen.css
===================================================================
--- trunk/examples/nestedbooking/view/css/screen.css 2008-11-25 23:12:19 UTC (rev 9644)
+++ trunk/examples/nestedbooking/view/css/screen.css 2008-11-25 23:15:42 UTC (rev 9645)
@@ -267,6 +267,6 @@
#pgHome #content {
margin-top: 183px;
}
-#pgHome input[type="submit"] {
+#pgHome #sidebar input[type="submit"] {
height: 30px;
}
Modified: trunk/examples/spring/view/css/screen.css
===================================================================
--- trunk/examples/spring/view/css/screen.css 2008-11-25 23:12:19 UTC (rev 9644)
+++ trunk/examples/spring/view/css/screen.css 2008-11-25 23:15:42 UTC (rev 9645)
@@ -267,6 +267,6 @@
#pgHome #content {
margin-top: 183px;
}
-#pgHome input[type="submit"] {
+#pgHome #sidebar input[type="submit"] {
height: 30px;
}
15 years, 12 months
Seam SVN: r9644 - in trunk/examples/jee5/remoting: nbproject and 1 other directory.
by seam-commits@lists.jboss.org
Author: dan.j.allen
Date: 2008-11-25 18:12:19 -0500 (Tue, 25 Nov 2008)
New Revision: 9644
Modified:
trunk/examples/jee5/remoting/build.xml
trunk/examples/jee5/remoting/nbproject/project.xml
Log:
update project name and context
Modified: trunk/examples/jee5/remoting/build.xml
===================================================================
--- trunk/examples/jee5/remoting/build.xml 2008-11-25 23:11:19 UTC (rev 9643)
+++ trunk/examples/jee5/remoting/build.xml 2008-11-25 23:12:19 UTC (rev 9644)
@@ -1,10 +1,10 @@
<?xml version="1.0"?>
-<project name="Java EE 5 Remoting Test" default="archive" basedir=".">
+<project name="Java EE 5 Remoting Example" default="archive" basedir=".">
<!-- Naming -->
- <property name="Name" value="The Java EE 5 Example for GlassFish"/>
- <property name="example.name" value="jboss-seam-remoting"/>
+ <property name="Name" value="Java EE 5 Remoting Example (GlassFish V2/JBoss AS 5)"/>
+ <property name="example.name" value="jboss-seam-jee5-remoting"/>
<!-- resources -->
<property name="resources.dir" value="resources" />
Modified: trunk/examples/jee5/remoting/nbproject/project.xml
===================================================================
--- trunk/examples/jee5/remoting/nbproject/project.xml 2008-11-25 23:11:19 UTC (rev 9643)
+++ trunk/examples/jee5/remoting/nbproject/project.xml 2008-11-25 23:12:19 UTC (rev 9644)
@@ -4,7 +4,7 @@
<configuration>
<general-data xmlns="http://www.netbeans.org/ns/freeform-project/1">
<!-- Do not use Project Properties customizer when editing this file manually. -->
- <name>Seam Remoting Example</name>
+ <name>Java EE 5 Remoting Example</name>
<properties/>
<folders>
<source-folder>
15 years, 12 months
Seam SVN: r9643 - trunk.
by seam-commits@lists.jboss.org
Author: dan.j.allen
Date: 2008-11-25 18:11:19 -0500 (Tue, 25 Nov 2008)
New Revision: 9643
Modified:
trunk/
Log:
ignore dist dir
Property changes on: trunk
___________________________________________________________________
Name: svn:ignore
- *.ipr
*.iws
*.iml
jboss-seam.jar
jboss-seam-ui.jar
jboss-seam-debug.jar
jboss-seam-gen.jar
jboss-seam-pdf.jar
jboss-seam-mail.jar
jboss-seam-remoting.jar
jboss-seam-ioc.jar
jboss-seam-trinidad.jar
test-output
test-report
testng-failures.xml
report
output
classes
lib
.classpath
build.properties
coverage.ec
dvdindexes
coverage-output
blogindexes
.ant-targets-build.xml
dependency-report.txt
lacewikiIndex
jmimemagic.log
+ *.ipr
*.iws
*.iml
jboss-seam.jar
jboss-seam-ui.jar
jboss-seam-debug.jar
jboss-seam-gen.jar
jboss-seam-pdf.jar
jboss-seam-mail.jar
jboss-seam-remoting.jar
jboss-seam-ioc.jar
jboss-seam-trinidad.jar
test-output
test-report
testng-failures.xml
report
output
classes
lib
.classpath
build.properties
coverage.ec
dvdindexes
coverage-output
blogindexes
.ant-targets-build.xml
dependency-report.txt
lacewikiIndex
jmimemagic.log
dist
15 years, 12 months
Seam SVN: r9642 - trunk/examples/jee5/booking.
by seam-commits@lists.jboss.org
Author: dan.j.allen
Date: 2008-11-25 17:55:24 -0500 (Tue, 25 Nov 2008)
New Revision: 9642
Modified:
trunk/examples/jee5/booking/build.xml
Log:
update name and context for example
Modified: trunk/examples/jee5/booking/build.xml
===================================================================
--- trunk/examples/jee5/booking/build.xml 2008-11-25 17:03:12 UTC (rev 9641)
+++ trunk/examples/jee5/booking/build.xml 2008-11-25 22:55:24 UTC (rev 9642)
@@ -3,8 +3,8 @@
<project name="Java EE 5 Booking" default="archive" basedir=".">
<!-- Naming -->
- <property name="Name" value="The Java EE 5 Example for GlassFish"/>
- <property name="example.name" value="jboss-seam-jee5"/>
+ <property name="Name" value="Java EE 5 Booking Example (GlassFish V2/JBoss AS 5)"/>
+ <property name="example.name" value="jboss-seam-jee5-booking"/>
<!-- resources -->
<property name="resources.dir" value="resources" />
15 years, 12 months
Seam SVN: r9641 - in trunk: examples/groovybooking/resources and 3 other directories.
by seam-commits@lists.jboss.org
Author: jharting
Date: 2008-11-25 12:03:12 -0500 (Tue, 25 Nov 2008)
New Revision: 9641
Modified:
trunk/build/validate.xml
trunk/examples/groovybooking/resources/WEB-INF/jboss-web.xml
trunk/examples/groovybooking/resources/groovybooking-dev-ds.xml
trunk/examples/groovybooking/resources/groovybooking-prod-ds.xml
trunk/examples/nestedbooking/resources/META-INF/jboss-app.xml
trunk/examples/nestedbooking/resources/jboss-seam-nestedbooking-ds.xml
Log:
JBSEAM-3756
Modified: trunk/build/validate.xml
===================================================================
--- trunk/build/validate.xml 2008-11-25 16:57:23 UTC (rev 9640)
+++ trunk/build/validate.xml 2008-11-25 17:03:12 UTC (rev 9641)
@@ -16,7 +16,7 @@
http://jboss.com/products/seam/navigation ${src.schema.dir}/navigation-${schema.version}.xsd
http://jboss.com/products/seam/pageflow ${src.schema.dir}/pageflow-${schema.version}.xsd
http://jboss.com/products/seam/pages ${src.schema.dir}/pages-${schema.version}.xsd
- http://jboss.com/products/seam/pdf ${src.schema.dir}/pdf-${schema.version}.xsd
+ http://jboss.com/products/seam/pdf ${seam.dir}/src/pdf/org/jboss/seam/pdf/pdf-${schema.version}.xsd
http://jboss.com/products/seam/persistence ${src.schema.dir}/persistence-${schema.version}.xsd
http://jboss.com/products/seam/remoting ${src.schema.dir}/remoting-${schema.version}.xsd
http://jboss.com/products/seam/security ${src.schema.dir}/security-${schema.version}.xsd
Modified: trunk/examples/groovybooking/resources/WEB-INF/jboss-web.xml
===================================================================
--- trunk/examples/groovybooking/resources/WEB-INF/jboss-web.xml 2008-11-25 16:57:23 UTC (rev 9640)
+++ trunk/examples/groovybooking/resources/WEB-INF/jboss-web.xml 2008-11-25 17:03:12 UTC (rev 9641)
@@ -1,8 +1,12 @@
-<jboss-web>
- <class-loading java2ClassLoadingCompliance="false">
- <loader-repository>
- seam.jboss.org:loader=jboss-seam-groovybooking
- <loader-repository-config>java2ParentDelegation=false</loader-repository-config>
- </loader-repository>
- </class-loading>
+<!DOCTYPE jboss-web PUBLIC
+ "-//JBoss//DTD Web Application 4.2//EN"
+ "http://www.jboss.org/j2ee/dtd/jboss-web_4_2.dtd">
+
+<jboss-web>
+ <class-loading java2ClassLoadingCompliance="false">
+ <loader-repository>
+ seam.jboss.org:loader=jboss-seam-groovybooking
+ <loader-repository-config>java2ParentDelegation=false</loader-repository-config>
+ </loader-repository>
+ </class-loading>
</jboss-web>
Modified: trunk/examples/groovybooking/resources/groovybooking-dev-ds.xml
===================================================================
--- trunk/examples/groovybooking/resources/groovybooking-dev-ds.xml 2008-11-25 16:57:23 UTC (rev 9640)
+++ trunk/examples/groovybooking/resources/groovybooking-dev-ds.xml 2008-11-25 17:03:12 UTC (rev 9641)
@@ -1,4 +1,9 @@
<?xml version="1.0" encoding="UTF-8"?>
+
+<!DOCTYPE datasources
+ PUBLIC "-//JBoss//DTD JBOSS JCA Config 1.5//EN"
+ "http://www.jboss.org/j2ee/dtd/jboss-ds_1_5.dtd">
+
<datasources>
<local-tx-datasource>
Modified: trunk/examples/groovybooking/resources/groovybooking-prod-ds.xml
===================================================================
--- trunk/examples/groovybooking/resources/groovybooking-prod-ds.xml 2008-11-25 16:57:23 UTC (rev 9640)
+++ trunk/examples/groovybooking/resources/groovybooking-prod-ds.xml 2008-11-25 17:03:12 UTC (rev 9641)
@@ -1,4 +1,9 @@
<?xml version="1.0" encoding="UTF-8"?>
+
+<!DOCTYPE datasources
+ PUBLIC "-//JBoss//DTD JBOSS JCA Config 1.5//EN"
+ "http://www.jboss.org/j2ee/dtd/jboss-ds_1_5.dtd">
+
<datasources>
<local-tx-datasource>
Modified: trunk/examples/nestedbooking/resources/META-INF/jboss-app.xml
===================================================================
--- trunk/examples/nestedbooking/resources/META-INF/jboss-app.xml 2008-11-25 16:57:23 UTC (rev 9640)
+++ trunk/examples/nestedbooking/resources/META-INF/jboss-app.xml 2008-11-25 17:03:12 UTC (rev 9641)
@@ -1,3 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+ <!DOCTYPE jboss-app
+ PUBLIC "-//JBoss//DTD J2EE Application 4.2//EN"
+ "http://www.jboss.org/j2ee/dtd/jboss-app_4_2.dtd">
+
<jboss-app>
<loader-repository>
seam.jboss.org:loader=seam-nestedbooking
Modified: trunk/examples/nestedbooking/resources/jboss-seam-nestedbooking-ds.xml
===================================================================
--- trunk/examples/nestedbooking/resources/jboss-seam-nestedbooking-ds.xml 2008-11-25 16:57:23 UTC (rev 9640)
+++ trunk/examples/nestedbooking/resources/jboss-seam-nestedbooking-ds.xml 2008-11-25 17:03:12 UTC (rev 9641)
@@ -1,5 +1,9 @@
<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE datasources
+ PUBLIC "-//JBoss//DTD JBOSS JCA Config 1.5//EN"
+ "http://www.jboss.org/j2ee/dtd/jboss-ds_1_5.dtd">
+
<datasources>
<local-tx-datasource>
<jndi-name>nestedBookingDatasource</jndi-name>
16 years
Seam SVN: r9640 - trunk/build.
by seam-commits@lists.jboss.org
Author: dan.j.allen
Date: 2008-11-25 11:57:23 -0500 (Tue, 25 Nov 2008)
New Revision: 9640
Modified:
trunk/build/ci.build.xml
Log:
dvd example was renamed to dvdstore
Modified: trunk/build/ci.build.xml
===================================================================
--- trunk/build/ci.build.xml 2008-11-25 16:27:29 UTC (rev 9639)
+++ trunk/build/ci.build.xml 2008-11-25 16:57:23 UTC (rev 9640)
@@ -86,7 +86,7 @@
<deployExample name="booking" repositoryId="snapshots.jboss.org" />
<deployExampleNoDs name="numberguess" repositoryId="snapshots.jboss.org" />
<deployExampleNoDs name="jpa" distdir="dist-jboss" type="war" repositoryId="snapshots.jboss.org" />
- <deployExample name="dvd" path="${seam.dir}/examples/dvdstore" repositoryId="snapshots.jboss.org" />
+ <deployExample name="dvdstore" path="${seam.dir}/examples/dvdstore" repositoryId="snapshots.jboss.org" />
</target>
<target name="deployDocumentation" depends="initdav, initpoms">
@@ -137,4 +137,4 @@
</sequential>
</macrodef>
-</project>
\ No newline at end of file
+</project>
16 years
Seam SVN: r9639 - in trunk: build and 1 other directory.
by seam-commits@lists.jboss.org
Author: jharting
Date: 2008-11-25 11:27:29 -0500 (Tue, 25 Nov 2008)
New Revision: 9639
Modified:
trunk/build.xml
trunk/build/sample.build.properties
trunk/release-process.txt
Log:
JBSEAM-3751 fixed validateall target
Modified: trunk/build/sample.build.properties
===================================================================
--- trunk/build/sample.build.properties 2008-11-25 04:52:49 UTC (rev 9638)
+++ trunk/build/sample.build.properties 2008-11-25 16:27:29 UTC (rev 9639)
@@ -10,8 +10,6 @@
#
# Misc Settings
# -------------
-# Enabled validation of example XML descriptors
-#validate.xml true
# Directory in which to put build distribution, defaults to ../jboss-seam-${version}.${patchlevel}
#dist.dir ../jboss-seam-dist
# alphanumeric qualifier for the version number
Modified: trunk/build.xml
===================================================================
--- trunk/build.xml 2008-11-25 04:52:49 UTC (rev 9638)
+++ trunk/build.xml 2008-11-25 16:27:29 UTC (rev 9639)
@@ -509,15 +509,33 @@
</target>
<target name="validateall" description="Validate all example XML Configuration Files">
<ant dir="examples/booking" target="validateConfiguration" inheritall="false" />
+ <ant dir="examples/blog" target="validateConfiguration" inheritall="false" />
+ <ant dir="examples/contactlist" target="validateConfiguration" inheritall="false" />
<ant dir="examples/dvdstore" target="validateConfiguration" inheritall="false" />
+ <ant dir="examples/drools" target="validateConfiguration" inheritall="false" />
+ <ant dir="examples/excel" target="validateConfiguration" inheritall="false" />
+ <ant dir="examples/groovybooking" target="validateConfiguration" inheritall="false" />
+ <ant dir="examples/icefaces" target="validateConfiguration" inheritall="false" />
+ <ant dir="examples/itext" target="validateConfiguration" inheritall="false" />
+ <ant dir="examples/mail" target="validateConfiguration" inheritall="false" />
<ant dir="examples/messages" target="validateConfiguration" inheritall="false" />
+ <ant dir="examples/nestedbooking" target="validateConfiguration" inheritall="false" />
<ant dir="examples/numberguess" target="validateConfiguration" inheritall="false" />
- <ant dir="examples/contactlist" target="validateConfiguration" inheritall="false" />
+ <ant dir="examples/quartz" target="validateConfiguration" inheritall="false" />
<ant dir="examples/registration" target="validateConfiguration" inheritall="false" />
+ <ant dir="examples/remoting/chatroom" target="validateConfiguration" inheritall="false" />
+ <ant dir="examples/remoting/gwt" target="validateConfiguration" inheritall="false" />
+ <ant dir="examples/remoting/helloworld" target="validateConfiguration" inheritall="false" />
+ <ant dir="examples/remoting/progressbar" target="validateConfiguration" inheritall="false" />
+ <ant dir="examples/rss" target="validateConfiguration" inheritall="false" />
+ <ant dir="examples/seambay" target="validateConfiguration" inheritall="false" />
+ <ant dir="examples/seamdiscs" target="validateConfiguration" inheritall="false" />
+ <ant dir="examples/seampay" target="validateConfiguration" inheritall="false" />
+ <ant dir="examples/seamspace" target="validateConfiguration" inheritall="false" />
<ant dir="examples/todo" target="validateConfiguration" inheritall="false" />
- <ant dir="examples/blog" target="validateConfiguration" inheritall="false" />
- <!--<ant dir="examples/seamdiscs" target="validateConfiguration" inheritall="false" />-->
- <!--<ant dir="examples/portal" target="validateConfiguration" inheritall="false" />-->
+ <ant dir="examples/ui" target="validateConfiguration" inheritall="false" />
+ <ant dir="examples/wicket" target="validateConfiguration" inheritall="false" />
+
</target>
Modified: trunk/release-process.txt
===================================================================
--- trunk/release-process.txt 2008-11-25 04:52:49 UTC (rev 9638)
+++ trunk/release-process.txt 2008-11-25 16:27:29 UTC (rev 9639)
@@ -167,7 +167,7 @@
- <TODO: A tool is needed to do this effectively/>
** Testsuite execution **
- - "ant -Dvalidate.xml=true cleanall testall testreport
+ - "ant cleanall validateall testall testreport
> ../releaselogs/x.x.x.XX.testallreport.txt"
- check report/junit-noframes.html
- There should be no failures or errors.
16 years
Seam SVN: r9638 - trunk/src/test/ftest/examples/groovybooking.
by seam-commits@lists.jboss.org
Author: dan.j.allen
Date: 2008-11-24 23:52:49 -0500 (Mon, 24 Nov 2008)
New Revision: 9638
Modified:
trunk/src/test/ftest/examples/groovybooking/build.xml
trunk/src/test/ftest/examples/groovybooking/jboss.xml
Log:
JBSEAM-3579
JBSEAM-3612
Modified: trunk/src/test/ftest/examples/groovybooking/build.xml
===================================================================
--- trunk/src/test/ftest/examples/groovybooking/build.xml 2008-11-25 04:52:37 UTC (rev 9637)
+++ trunk/src/test/ftest/examples/groovybooking/build.xml 2008-11-25 04:52:49 UTC (rev 9638)
@@ -24,7 +24,7 @@
<property name="example.name" value="groovybooking" />
<property name="jboss.deploy.target" value="jbosswar.deploy" />
<property name="jboss.undeploy.target" value="undeploy" />
- <property name="jbosss.example.ready.check.url" value="jboss-seam-groovy/home.seam"/>
+ <property name="jbosss.example.ready.check.url" value="jboss-seam-groovybooking/home.seam"/>
<import file="../build.xml" />
Modified: trunk/src/test/ftest/examples/groovybooking/jboss.xml
===================================================================
--- trunk/src/test/ftest/examples/groovybooking/jboss.xml 2008-11-25 04:52:37 UTC (rev 9637)
+++ trunk/src/test/ftest/examples/groovybooking/jboss.xml 2008-11-25 04:52:49 UTC (rev 9638)
@@ -24,7 +24,7 @@
<test name="groovybooking_jboss">
<parameter name="PROPERTY_FILE"
value="/org/jboss/seam/example/groovybooking/test/selenium/groovybooking.properties" />
- <parameter name="CONTEXT_PATH" value="/jboss-seam-groovy" />
+ <parameter name="CONTEXT_PATH" value="/jboss-seam-groovybooking" />
<classes>
<class
name="org.jboss.seam.example.common.test.booking.selenium.RegistrationTest" />
@@ -38,4 +38,4 @@
name="org.jboss.seam.example.common.test.booking.selenium.ConversationTest" />
</classes>
</test>
-</suite>
\ No newline at end of file
+</suite>
16 years
Seam SVN: r9637 - in trunk/examples: groovybooking and 13 other directories.
by seam-commits@lists.jboss.org
Author: dan.j.allen
Date: 2008-11-24 23:52:37 -0500 (Mon, 24 Nov 2008)
New Revision: 9637
Added:
trunk/examples/groovybooking/build.properties
trunk/examples/jpa/build-jboss5.xml
Modified:
trunk/examples/build.xml
trunk/examples/groovybooking/build.xml
trunk/examples/groovybooking/readme.txt
trunk/examples/groovybooking/resources/META-INF/persistence-dev-war.xml
trunk/examples/groovybooking/resources/META-INF/persistence-prod-war.xml
trunk/examples/groovybooking/resources/WEB-INF/components.xml
trunk/examples/hibernate/build-glassfish.xml
trunk/examples/hibernate/build.xml
trunk/examples/hibernate/readme.txt
trunk/examples/jee5/booking/build.xml
trunk/examples/jee5/booking/resources/META-INF/persistence.xml
trunk/examples/jee5/readme.txt
trunk/examples/jee5/remoting/build.xml
trunk/examples/jpa/build-glassfish.xml
trunk/examples/jpa/build.xml
trunk/examples/jpa/readme.txt
trunk/examples/jpa/resources-glassfish/META-INF/persistence.xml
trunk/examples/jpa/resources-glassfish/WEB-INF/components.xml
trunk/examples/jpa/resources-glassfish/WEB-INF/web.xml
trunk/examples/jpa/resources-jboss/META-INF/persistence.xml
trunk/examples/jpa/resources-jboss/WEB-INF/components.xml
trunk/examples/jpa/resources-websphere61/META-INF/persistence.xml
Log:
JBSEAM-3579
JBSEAM-3612
Modified: trunk/examples/build.xml
===================================================================
--- trunk/examples/build.xml 2008-11-25 04:51:13 UTC (rev 9636)
+++ trunk/examples/build.xml 2008-11-25 04:52:37 UTC (rev 9637)
@@ -21,6 +21,9 @@
<!-- ###################### PROPERTY DEFINITIONS ###################### -->
+ <!-- Settings -->
+ <property name="loadPersistenceUnits" value="true"/>
+
<!-- Source directories -->
<property name="src.java.dir" value="src" />
<property name="src.test.dir" value="src" />
@@ -645,6 +648,7 @@
<filter token="debug" value="${debug}" />
<filter token="jndiPattern" value="${example.name}/#{ejbName}/local" />
<filter token="embeddedEjb" value="false" />
+ <filter token="loadPersistenceUnits" value="${loadPersistenceUnits}" />
</filterset>
</copy>
</target>
@@ -903,6 +907,7 @@
<filter token="debug" value="${debug}" />
<filter token="jndiPattern" value="#{ejbName}/local" />
<filter token="embeddedEjb" value="false" />
+ <filter token="loadPersistenceUnits" value="${loadPersistenceUnits}" />
</filterset>
</copy>
</target>
Added: trunk/examples/groovybooking/build.properties
===================================================================
--- trunk/examples/groovybooking/build.properties (rev 0)
+++ trunk/examples/groovybooking/build.properties 2008-11-25 04:52:37 UTC (rev 9637)
@@ -0,0 +1,2 @@
+# Uncomment when deploying to JBoss AS 5
+#loadPersistenceUnits=false
Modified: trunk/examples/groovybooking/build.xml
===================================================================
--- trunk/examples/groovybooking/build.xml 2008-11-25 04:51:13 UTC (rev 9636)
+++ trunk/examples/groovybooking/build.xml 2008-11-25 04:52:37 UTC (rev 9637)
@@ -4,8 +4,11 @@
<!-- Example name -->
<property name="Name" value="Seam Groovy Example" />
- <property name="example.name" value="jboss-seam-groovy" />
+ <property name="example.name" value="jboss-seam-groovybooking" />
+ <!-- Give user a chance to override without editing this file or typing -D -->
+ <property file="${basedir}/build.properties" />
+
<!-- Libraries -->
<property name="seam.ui.lib" value="yes" />
<property name="seam.debug.lib" value="yes" />
Modified: trunk/examples/groovybooking/readme.txt
===================================================================
--- trunk/examples/groovybooking/readme.txt 2008-11-25 04:51:13 UTC (rev 9636)
+++ trunk/examples/groovybooking/readme.txt 2008-11-25 04:52:37 UTC (rev 9637)
@@ -6,6 +6,9 @@
Thus, you prefix all the typical targets (explode, restart, unexplode) with
"jbosswar." (e.g., jbosswar.explode, jbosswar.restart, jbosswar.unexplode).
+Please note that you need to uncomment the loadPersistenceUnits=true property
+in build.properties when deploying to JBoss AS 5.
+
When editing Groovy files from the src/action directory, you can run ant
"jbosswar.explode" to see your changes take effect. When editing Groovy files
from src/model, you need to run "ant jbosswar.explode jbosswar.restart"
Modified: trunk/examples/groovybooking/resources/META-INF/persistence-dev-war.xml
===================================================================
--- trunk/examples/groovybooking/resources/META-INF/persistence-dev-war.xml 2008-11-25 04:51:13 UTC (rev 9636)
+++ trunk/examples/groovybooking/resources/META-INF/persistence-dev-war.xml 2008-11-25 04:52:37 UTC (rev 9637)
@@ -12,6 +12,9 @@
<property name="hibernate.hbm2ddl.auto" value="create-drop"/>
<property name="hibernate.show_sql" value="true"/>
<property name="hibernate.transaction.manager_lookup_class" value="org.hibernate.transaction.JBossTransactionManagerLookup"/>
+ <!-- Binds the EntityManagerFactory to JNDI where Seam can look it up.
+ This is only relevant when the container automatically loads the persistence unit, as is the case in JBoss AS 5. -->
+ <property name="jboss.entity.manager.factory.jndi.name" value="java:/groovyEntityManagerFactory"/>
</properties>
</persistence-unit>
Modified: trunk/examples/groovybooking/resources/META-INF/persistence-prod-war.xml
===================================================================
--- trunk/examples/groovybooking/resources/META-INF/persistence-prod-war.xml 2008-11-25 04:51:13 UTC (rev 9636)
+++ trunk/examples/groovybooking/resources/META-INF/persistence-prod-war.xml 2008-11-25 04:52:37 UTC (rev 9637)
@@ -12,6 +12,9 @@
<property name="hibernate.hbm2ddl.auto" value="validate"/>
<property name="hibernate.jdbc.batch_size" value="20"/>
<property name="hibernate.transaction.manager_lookup_class" value="org.hibernate.transaction.JBossTransactionManagerLookup"/>
+ <!-- Binds the EntityManagerFactory to JNDI where Seam can look it up.
+ This is only relevant when the container automatically loads the persistence unit, as is the case in JBoss AS 5. -->
+ <property name="jboss.entity.manager.factory.jndi.name" value="java:/groovyEntityManagerFactory"/>
</properties>
</persistence-unit>
Modified: trunk/examples/groovybooking/resources/WEB-INF/components.xml
===================================================================
--- trunk/examples/groovybooking/resources/WEB-INF/components.xml 2008-11-25 04:51:13 UTC (rev 9636)
+++ trunk/examples/groovybooking/resources/WEB-INF/components.xml 2008-11-25 04:52:37 UTC (rev 9637)
@@ -20,12 +20,14 @@
conversation-timeout="120000"
conversation-id-parameter="cid"/>
- <persistence:managed-persistence-context name="em"
- auto-create="true"
- entity-manager-factory="#{groovyEntityManagerFactory}"/>
+ <persistence:entity-manager-factory name="groovyEntityManagerFactory"
+ persistence-unit-name="groovy" installed="@loadPersistenceUnits@"/>
- <persistence:entity-manager-factory name="groovyEntityManagerFactory"
- persistence-unit-name="groovy"/>
+ <!-- If Seam loads the persistence unit (JBoss 4.x), the EntityManagerFactory will be resolved from #{groovyEntityManagerFactory}.
+ On JBoss AS 5, the EntityManagerFactory is retrieved from JNDI (the binding occurs during application deployment). -->
+ <persistence:managed-persistence-context name="em" auto-create="true"
+ entity-manager-factory="#{groovyEntityManagerFactory}"
+ persistence-unit-jndi-name="java:/groovyEntityManagerFactory"/>
<security:identity authenticate-method="#{authenticator.authenticate}"
remember-me="true"/>
Modified: trunk/examples/hibernate/build-glassfish.xml
===================================================================
--- trunk/examples/hibernate/build-glassfish.xml 2008-11-25 04:51:13 UTC (rev 9636)
+++ trunk/examples/hibernate/build-glassfish.xml 2008-11-25 04:52:37 UTC (rev 9637)
@@ -3,7 +3,7 @@
<project name="Hibernate Booking" default="noejb.archive" basedir=".">
<!-- Naming -->
- <property name="Name" value="The Hibernate Example for Glassfish"/>
+ <property name="Name" value="The Hibernate Example for GlassFish"/>
<property name="example.name" value="jboss-seam-hibernate"/>
<!-- resources -->
Modified: trunk/examples/hibernate/build.xml
===================================================================
--- trunk/examples/hibernate/build.xml 2008-11-25 04:51:13 UTC (rev 9636)
+++ trunk/examples/hibernate/build.xml 2008-11-25 04:52:37 UTC (rev 9637)
@@ -22,7 +22,7 @@
<ant antfile="build-jboss405.xml"/>
</target>
- <target name="glassfish" description="Build the Hibernate Booking example artifacts, suitable for deployment to Glassfish V2">
+ <target name="glassfish" description="Build the Hibernate Booking example artifacts, suitable for deployment to GlassFish V2">
<ant antfile="build-glassfish.xml"/>
</target>
Modified: trunk/examples/hibernate/readme.txt
===================================================================
--- trunk/examples/hibernate/readme.txt 2008-11-25 04:51:13 UTC (rev 9636)
+++ trunk/examples/hibernate/readme.txt 2008-11-25 04:52:37 UTC (rev 9637)
@@ -2,7 +2,7 @@
=======================
This is the Hotel Booking example implemented in Seam and Hibernate POJOs.
-It can be deployed in JBoss AS 4.x, WebLogic, Glassfish and Tomcat without
+It can be deployed in JBoss AS 4.x, WebLogic, GlassFish and Tomcat without
the EJB3 container.
JBoss AS 4.2.x:
@@ -53,20 +53,29 @@
* Start Tomcat
* Access the app at http://localhost:8080/jboss-seam-hibernate/
-Glassfish
- * Install Glassfish V1 or V2
+GlassFish
+ * Install GlassFish V1 or V2
* ant glassfish
- * Start GlassFish
+ * Start GlassFish and the Embedded Derby Database
* Load the admin console http://localhost:4848/
* Deploy dist-glassfish/jboss-seam-hibernate.war as Web App
* Access the app at http://localhost:8080/jboss-seam-hibernate/
+GlassFish:
+ * Install GlassFish V1 or V2
+ * ant glassfish
+ * Start GlassFish and the Embedded Derby Database
+ * Load the admin console http://localhost:4848/
+ * Deploy dist-glassfish/jboss-seam-hibernate.war in the Admin Console (Applications > Web Applications)
+ or using the command $GLASSFISH_HOME/bin/asadmin deploy dist-glassfish/jboss-seam-hibernate.war
+ * Access the app at http://localhost:8080/jboss-seam-hibernate/
+
NOTES FOR GLASSFISH USERS:
- In order for the app to work out of the box with Glassfish, we have
- used the Derby (i.e. Java DB) database in Glassfish. However,
- we strongly recommend you to use a non-Derby data source (e.g., HSQL
- is a much better embedded DB) if possible. The
- WEB/classes/GlassfishDerbyDialect.class is a special hack to get around
- a Derby bug in Glassfish TM. You must use it as your Hibernate dialect
- if you are using Derby with Glassfish.
-
+ In order for the app to work out of the box with GlassFish, we have
+ used the Derby (i.e., Java DB) database in GlassFish. The included
+ WEB-INF/classes/GlassfishDerbyDialect.class is a special hack to get
+ around a Derby bug in GlassFish V2. You must use it as your Hibernate
+ dialect if you use Derby with GlassFish.
+
+ However, we strongly recommend you to use a non-Derby data source if
+ possible (for example, HSQL is a much better embedded DB).
Modified: trunk/examples/jee5/booking/build.xml
===================================================================
--- trunk/examples/jee5/booking/build.xml 2008-11-25 04:51:13 UTC (rev 9636)
+++ trunk/examples/jee5/booking/build.xml 2008-11-25 04:52:37 UTC (rev 9637)
@@ -3,7 +3,7 @@
<project name="Java EE 5 Booking" default="archive" basedir=".">
<!-- Naming -->
- <property name="Name" value="The Java EE 5 Example for Glassfish"/>
+ <property name="Name" value="The Java EE 5 Example for GlassFish"/>
<property name="example.name" value="jboss-seam-jee5"/>
<!-- resources -->
Modified: trunk/examples/jee5/booking/resources/META-INF/persistence.xml
===================================================================
--- trunk/examples/jee5/booking/resources/META-INF/persistence.xml 2008-11-25 04:51:13 UTC (rev 9636)
+++ trunk/examples/jee5/booking/resources/META-INF/persistence.xml 2008-11-25 04:52:37 UTC (rev 9637)
@@ -7,7 +7,7 @@
<provider>org.hibernate.ejb.HibernatePersistence</provider>
<jta-data-source>jdbc/__default</jta-data-source>
<properties>
- <!-- The following two properties are for Glassfish -->
+ <!-- The following two properties are for GlassFish -->
<property name="hibernate.dialect"
value="org.hibernate.dialect.DerbyDialect"/>
<property name="hibernate.transaction.manager_lookup_class"
Modified: trunk/examples/jee5/readme.txt
===================================================================
--- trunk/examples/jee5/readme.txt 2008-11-25 04:51:13 UTC (rev 9636)
+++ trunk/examples/jee5/readme.txt 2008-11-25 04:52:37 UTC (rev 9637)
@@ -4,36 +4,36 @@
The examples in this directory showcases how to build Java EE 5 compliant Seam
applications. The application should run on all Java EE 5 compliant
application servers with minimal changes in code and configuration files. The
-default build script builds a deployable EAR for Glassfish. See Seam reference
+default build script builds a deployable EAR for GlassFish. See Seam reference
guide for instructions for other containers.
-Glassfish v2
+GlassFish V2
------------
1. Build the demo app by running ANT. The build target is
"dist/jboss-seam-jee5.ear"
-2. Download Glassfish V2 Final Build
+2. Download GlassFish V2 Final Build
3. Install it: java -Xmx256m -jar glassfish-installer-xxx.jar
4. Setup glassfish: cd glassfish; ant -f setup.xml;
-5. Start the Glassfish server: bin/asadmin start-domain domain1
+5. Start the GlassFish server: $GLASSFISH_HOME/bin/asadmin start-domain domain1
-6. Start the embedded JavaDB: bin/asadmin start-database
+6. Start the embedded JavaDB: $GLASSFISH_HOME/bin/asadmin start-database
7. Load the admin console: http://localhost:4848/
8. Login using username/password: admin / adminadmin
-9. Deploy the "enterprise application" in the admin console:
- The app is located at SEAM_HOME/examples/jee5/booking/dist/jboss-seam-jee5.ear
+9. Deploy the "Enterprise Application" in the admin console
+ or using the command $GLASSFISH_HOME/bin/asadmin deploy dist/jboss-seam-jee5.ear
10. Checkout the app at: http://localhost:8080/seam-jee5/
11. Stop the server and database:
- bin/asadmin stop-domain domain1; bin/asadmin stop-database
+ $GLASSFISH_HOME/bin/asadmin stop-domain domain1; $GLASSFISH_HOME/bin/asadmin stop-database
OC4J 11g Technology Preview
@@ -42,7 +42,7 @@
1. Modify the following files in the project.
* build.xml: Un-comment the OC4J-related libraries
- * resources/META-INF/persistence.xml: Comment out the Glassfish properties
+ * resources/META-INF/persistence.xml: Comment out the GlassFish properties
and un-comment the OC4J properties
2. Build the demo app by running ANT. The build target is
@@ -138,4 +138,4 @@
The instructions for integration with Websphere are fairly verbose. Please
refer to the Seam reference guide for additional information.
-- http://seamframework.org/Documentation
\ No newline at end of file
+- http://seamframework.org/Documentation
Modified: trunk/examples/jee5/remoting/build.xml
===================================================================
--- trunk/examples/jee5/remoting/build.xml 2008-11-25 04:51:13 UTC (rev 9636)
+++ trunk/examples/jee5/remoting/build.xml 2008-11-25 04:52:37 UTC (rev 9637)
@@ -3,7 +3,7 @@
<project name="Java EE 5 Remoting Test" default="archive" basedir=".">
<!-- Naming -->
- <property name="Name" value="The Java EE 5 Example for Glassfish"/>
+ <property name="Name" value="The Java EE 5 Example for GlassFish"/>
<property name="example.name" value="jboss-seam-remoting"/>
<!-- resources -->
Modified: trunk/examples/jpa/build-glassfish.xml
===================================================================
--- trunk/examples/jpa/build-glassfish.xml 2008-11-25 04:51:13 UTC (rev 9636)
+++ trunk/examples/jpa/build-glassfish.xml 2008-11-25 04:52:37 UTC (rev 9637)
@@ -3,7 +3,7 @@
<project name="JPA Booking" default="noejb.archive" basedir=".">
<!-- Naming -->
- <property name="Name" value="The JPA Example for Glassfish"/>
+ <property name="Name" value="The JPA Example for GlassFish"/>
<property name="example.name" value="jboss-seam-jpa"/>
<!-- resources -->
Added: trunk/examples/jpa/build-jboss5.xml
===================================================================
--- trunk/examples/jpa/build-jboss5.xml (rev 0)
+++ trunk/examples/jpa/build-jboss5.xml 2008-11-25 04:52:37 UTC (rev 9637)
@@ -0,0 +1,26 @@
+<?xml version="1.0"?>
+
+<project name="JPA Booking" default="jbosswar.deploy" basedir=".">
+
+ <!-- Naming -->
+ <property name="Name" value="The JPA Example for JBoss 5.0.0.GA"/>
+ <property name="example.name" value="jboss-seam-jpa"/>
+
+ <!-- settings -->
+ <property name="loadPersistenceUnits" value="false"/>
+
+ <!-- resources -->
+ <property name="resources.dir" value="resources-jboss" />
+ <property name="dist.dir" value="dist-jboss" />
+ <property name="exploded-archives.dir" value="exploded-archives-jboss" />
+
+ <!-- Libraries to include -->
+ <property name="seam.ui.lib" value="true"/>
+ <property name="seam.debug.lib" value="true"/>
+ <property name="facelets.lib" value="true"/>
+ <property name="richfaces.lib" value="true"/>
+
+ <import file="../build.xml"/>
+
+</project>
+
Modified: trunk/examples/jpa/build.xml
===================================================================
--- trunk/examples/jpa/build.xml 2008-11-25 04:51:13 UTC (rev 9636)
+++ trunk/examples/jpa/build.xml 2008-11-25 04:52:37 UTC (rev 9637)
@@ -18,11 +18,15 @@
<ant antfile="build-jboss.xml" target="jbosswar.undeploy"/>
</target>
+ <target name="jboss5" description="Build the JPA artifacts, suitable for deployment to JBoss 5.0.0.GA">
+ <ant antfile="build-jboss5.xml"/>
+ </target>
+
<target name="jboss405" description="Build the JPA artifacts, suitable for deployment to JBoss 4.0.5.GA">
<ant antfile="build-jboss405.xml"/>
</target>
- <target name="glassfish" description="Build the JPA artifacts, suitable for deployment to Glassfish V2">
+ <target name="glassfish" description="Build the JPA artifacts, suitable for deployment to GlassFish V2">
<ant antfile="build-glassfish.xml"/>
</target>
Modified: trunk/examples/jpa/readme.txt
===================================================================
--- trunk/examples/jpa/readme.txt 2008-11-25 04:51:13 UTC (rev 9636)
+++ trunk/examples/jpa/readme.txt 2008-11-25 04:52:37 UTC (rev 9637)
@@ -2,7 +2,7 @@
================
This is the Hotel Booking example implemented in Seam POJO and Hibernate JPA.
-It can be deployed in JBoss AS 4.x, WebLogic, Glassfish, Tomcat (both with and
+It can be deployed in JBoss AS 4.x, WebLogic, GlassFish, Tomcat (both with and
without the EJB3 container).
JBoss AS 4.2.0:
@@ -65,20 +65,21 @@
* Start Tomcat
* Access the app at http://localhost:8080/jboss-seam-jpa/
-Glassfish:
- * Install Glassfish V2
+GlassFish:
+ * Install GlassFish V2
* ant glassfish
- * Start GlassFish
+ * Start GlassFish and the Embedded Derby Database
* Load the admin console http://localhost:4848/
- * Deploy dist-glassfish/jboss-seam-jpa.war as Web App
+ * Deploy dist-glassfish/jboss-seam-jpa.war in the admin console (Applications > Web Applications)
+ or using the command $GLASSFISH_HOME/bin/asadmin deploy dist-glassfish/jboss-seam-jpa.war
* Access the app at http://localhost:8080/jboss-seam-jpa/
NOTES FOR GLASSFISH USERS:
- In order for the app to work out of the box with Glassfish, we have
- used the Derby (i.e., Java DB) database in Glassfish. However,
- we strongly recommend you to use a non-Derby data source (e.g., HSQL
- is a much better embeded DB) if possible. The
- WEB/classes/GlassfishDerbyDialect.class is a special hack to get around
- a Derby bug in Glassfish TM. You must use it as your Hibernate dialect
- if you use Derby with Glassfish.
-
+ In order for the app to work out of the box with GlassFish, we have
+ used the Derby (i.e., Java DB) database in GlassFish. The included
+ WEB-INF/classes/GlassfishDerbyDialect.class is a special hack to get
+ around a Derby bug in GlassFish V2. You must use it as your Hibernate
+ dialect if you use Derby with GlassFish.
+
+ However, we strongly recommend you to use a non-Derby data source if
+ possible (for example, HSQL is a much better embedded DB).
Modified: trunk/examples/jpa/resources-glassfish/META-INF/persistence.xml
===================================================================
--- trunk/examples/jpa/resources-glassfish/META-INF/persistence.xml 2008-11-25 04:51:13 UTC (rev 9636)
+++ trunk/examples/jpa/resources-glassfish/META-INF/persistence.xml 2008-11-25 04:52:37 UTC (rev 9637)
@@ -7,12 +7,14 @@
<provider>org.hibernate.ejb.HibernatePersistence</provider>
<jta-data-source>jdbc/__default</jta-data-source>
<properties>
- <property name="hibernate.dialect"
- value="GlassfishDerbyDialect"/>
+ <property name="hibernate.dialect" value="GlassfishDerbyDialect"/>
<property name="hibernate.hbm2ddl.auto" value="create-drop"/>
<property name="hibernate.show_sql" value="true"/>
<property name="hibernate.cache.provider_class" value="org.hibernate.cache.HashtableCacheProvider"/>
+ <!-- Transaction manager lookup is only needed when Seam bootstraps the persistence unit (as opposed to the Java EE container) -->
+ <!--
<property name="hibernate.transaction.manager_lookup_class" value="org.hibernate.transaction.SunONETransactionManagerLookup"/>
+ -->
</properties>
</persistence-unit>
</persistence>
Modified: trunk/examples/jpa/resources-glassfish/WEB-INF/components.xml
===================================================================
--- trunk/examples/jpa/resources-glassfish/WEB-INF/components.xml 2008-11-25 04:51:13 UTC (rev 9636)
+++ trunk/examples/jpa/resources-glassfish/WEB-INF/components.xml 2008-11-25 04:52:37 UTC (rev 9637)
@@ -16,13 +16,12 @@
concurrent-request-timeout="500"
conversation-id-parameter="cid"/>
-
- <persistence:entity-manager-factory name="bookingDatabase"/>
-
- <persistence:managed-persistence-context name="em"
- auto-create="true"
- entity-manager-factory="#{bookingDatabase}"/>
+ <!-- You can choose to have Seam load the persistence unit using <persistence:entity-manager-factory>,
+ but we are leveraging the functionality baked into Java EE -->
+ <!-- The JNDI name where the EntityManagerFactory is stored is defined by the <persistence-unit-ref-name> element in web.xml -->
+ <persistence:managed-persistence-context name="em" auto-create="true" persistence-unit-jndi-name="java:comp/env/bookingEntityManagerFactory"/>
+
<security:identity authenticate-method="#{authenticator.authenticate}"/>
</components>
Modified: trunk/examples/jpa/resources-glassfish/WEB-INF/web.xml
===================================================================
--- trunk/examples/jpa/resources-glassfish/WEB-INF/web.xml 2008-11-25 04:51:13 UTC (rev 9636)
+++ trunk/examples/jpa/resources-glassfish/WEB-INF/web.xml 2008-11-25 04:52:37 UTC (rev 9637)
@@ -55,5 +55,10 @@
<param-value>true</param-value>
</context-param>
+ <!-- Forces the container to load the persistence unit when the application is deployed -->
+ <persistence-unit-ref>
+ <persistence-unit-ref-name>bookingEntityManagerFactory</persistence-unit-ref-name>
+ <persistence-unit-name>bookingDatabase</persistence-unit-name>
+ </persistence-unit-ref>
</web-app>
Modified: trunk/examples/jpa/resources-jboss/META-INF/persistence.xml
===================================================================
--- trunk/examples/jpa/resources-jboss/META-INF/persistence.xml 2008-11-25 04:51:13 UTC (rev 9636)
+++ trunk/examples/jpa/resources-jboss/META-INF/persistence.xml 2008-11-25 04:52:37 UTC (rev 9637)
@@ -11,10 +11,9 @@
<property name="hibernate.show_sql" value="true"/>
<property name="hibernate.cache.provider_class" value="org.hibernate.cache.HashtableCacheProvider"/>
<property name="hibernate.transaction.manager_lookup_class" value="org.hibernate.transaction.JBossTransactionManagerLookup"/>
- <!-- alternative
- <property name="jboss.entity.manager.factory.jndi.name"
- value="java:/jpaBookingEntityManagerFactory"/>
- -->
+ <!-- Binds the EntityManagerFactory to JNDI where Seam can look it up.
+ This is only relevant when the container automatically loads the persistence unit, as is the case in JBoss AS 5. -->
+ <property name="jboss.entity.manager.factory.jndi.name" value="java:/bookingEntityManagerFactory"/>
</properties>
</persistence-unit>
-</persistence>
\ No newline at end of file
+</persistence>
Modified: trunk/examples/jpa/resources-jboss/WEB-INF/components.xml
===================================================================
--- trunk/examples/jpa/resources-jboss/WEB-INF/components.xml 2008-11-25 04:51:13 UTC (rev 9636)
+++ trunk/examples/jpa/resources-jboss/WEB-INF/components.xml 2008-11-25 04:52:37 UTC (rev 9637)
@@ -18,11 +18,12 @@
<transaction:entity-transaction entity-manager="#{em}"/>
- <persistence:entity-manager-factory name="bookingDatabase"/>
-
- <persistence:managed-persistence-context name="em"
- auto-create="true"
- entity-manager-factory="#{bookingDatabase}"/>
+ <persistence:entity-manager-factory name="bookingDatabase" installed="@loadPersistenceUnits@"/>
+
+ <!-- If Seam loads the persistence unit (JBoss 4.x), the EntityManagerFactory will be resolved from #{bookingDatabase}.
+ On JBoss AS 5, the EntityManagerFactory is retrieved from JNDI (the binding occurs during application deployment). -->
+ <persistence:managed-persistence-context name="em" auto-create="true"
+ entity-manager-factory="#{bookingDatabase}" persistence-unit-jndi-name="java:/bookingEntityManagerFactory"/>
<security:identity authenticate-method="#{authenticator.authenticate}"/>
Modified: trunk/examples/jpa/resources-websphere61/META-INF/persistence.xml
===================================================================
--- trunk/examples/jpa/resources-websphere61/META-INF/persistence.xml 2008-11-25 04:51:13 UTC (rev 9636)
+++ trunk/examples/jpa/resources-websphere61/META-INF/persistence.xml 2008-11-25 04:52:37 UTC (rev 9637)
@@ -7,7 +7,7 @@
<provider>org.hibernate.ejb.HibernatePersistence</provider>
<jta-data-source>DefaultDatasource</jta-data-source>
<properties>
- <!-- From WAS 6.1.0.9, the embedded DB is switched to the same Derby DB in Glassfish -->
+ <!-- From WAS 6.1.0.9, the embedded DB is switched to the same Derby DB in GlassFish -->
<property name="hibernate.dialect" value="GlassfishDerbyDialect"/>
<property name="hibernate.hbm2ddl.auto" value="create-drop"/>
<property name="hibernate.show_sql" value="true"/>
16 years