Author: alexsmirnov
Date: 2008-06-09 21:38:06 -0400 (Mon, 09 Jun 2008)
New Revision: 8962
Added:
trunk/samples/seamIntegration/src/main/resources/META-INF/orm.xml
trunk/samples/seamIntegration/src/main/webapp/META-INF/context.xml
trunk/samples/seamIntegration/src/main/webapp/WEB-INF/jetty-env.xml
Modified:
trunk/samples/seamIntegration/pom.xml
trunk/samples/seamIntegration/src/main/resources/META-INF/persistence.xml
trunk/samples/seamIntegration/src/main/webapp/pages/repeater.xhtml
Log:
increase Seam & Hibernate versions
Modified: trunk/samples/seamIntegration/pom.xml
===================================================================
--- trunk/samples/seamIntegration/pom.xml 2008-06-09 23:42:04 UTC (rev 8961)
+++ trunk/samples/seamIntegration/pom.xml 2008-06-10 01:38:06 UTC (rev 8962)
@@ -63,40 +63,41 @@
<artifactId>richfaces-ui</artifactId>
<version>${version}</version>
</dependency>
+ <dependency>
+ <groupId>hsqldb</groupId>
+ <artifactId>hsqldb</artifactId>
+ <version>1.8.0.7</version>
+ <scope>runtime</scope>
+ </dependency>
<dependency>
<groupId>org.hibernate</groupId>
- <artifactId>hibernate-validator</artifactId>
- <version>3.0.0.GA</version>
+ <artifactId>hibernate-entitymanager</artifactId>
+ <version>3.3.2.GA</version>
</dependency>
<dependency>
- <groupId>org.hibernate</groupId>
- <artifactId>hibernate-annotations</artifactId>
- <version>3.3.0.ga</version>
- </dependency>
+ <groupId>org.hibernate</groupId>
+ <artifactId>hibernate-validator</artifactId>
+ <version>3.0.0.ga</version>
+ </dependency>
<dependency>
- <groupId>org.hibernate</groupId>
- <artifactId>hibernate-entitymanager</artifactId>
- <version>3.3.1.ga</version>
- </dependency>
- <dependency>
<groupId>org.jboss.seam</groupId>
<artifactId>jboss-seam</artifactId>
- <version>2.0.1.GA</version>
+ <version>2.0.2.GA</version>
</dependency>
<dependency>
<groupId>org.jboss.seam</groupId>
<artifactId>jboss-seam-ui</artifactId>
- <version>2.0.1.GA</version>
+ <version>2.0.2.GA</version>
</dependency>
<dependency>
<groupId>org.jboss.seam</groupId>
<artifactId>jboss-seam-ioc</artifactId>
- <version>2.0.1.GA</version>
+ <version>2.0.2.GA</version>
</dependency>
<dependency>
<groupId>org.jboss.seam</groupId>
<artifactId>jboss-seam-debug</artifactId>
- <version>2.0.1.GA</version>
+ <version>2.0.2.GA</version>
</dependency>
<dependency>
<groupId>javax.servlet</groupId>
Added: trunk/samples/seamIntegration/src/main/resources/META-INF/orm.xml
===================================================================
--- trunk/samples/seamIntegration/src/main/resources/META-INF/orm.xml
(rev 0)
+++ trunk/samples/seamIntegration/src/main/resources/META-INF/orm.xml 2008-06-10 01:38:06
UTC (rev 8962)
@@ -0,0 +1,3 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<entity-mappings
xmlns="http://java.sun.com/xml/ns/persistence/orm"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/persistence/orm
http://java.sun.com/xml/ns/persistence/orm_1_0.xsd" version="1.0">
+</entity-mappings>
Property changes on: trunk/samples/seamIntegration/src/main/resources/META-INF/orm.xml
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Modified: trunk/samples/seamIntegration/src/main/resources/META-INF/persistence.xml
===================================================================
--- trunk/samples/seamIntegration/src/main/resources/META-INF/persistence.xml 2008-06-09
23:42:04 UTC (rev 8961)
+++ trunk/samples/seamIntegration/src/main/resources/META-INF/persistence.xml 2008-06-10
01:38:06 UTC (rev 8962)
@@ -1,18 +1,18 @@
<?xml version="1.0" encoding="UTF-8"?>
-<!-- Persistence deployment descriptor for dev profile -->
-<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
http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd"
- version="1.0">
-
- <persistence-unit name="seamIntegration"
transaction-type="JTA">
- <provider>org.hibernate.ejb.HibernatePersistence</provider>
- <jta-data-source>java:/seamIntegrationDatasource</jta-data-source>
- <properties>
- <property name="hibernate.hbm2ddl.auto"
value="${hibernate.hbm2ddl.auto}"/>
- <property name="hibernate.show_sql" value="true"/>
- <property name="hibernate.transaction.manager_lookup_class"
value="org.hibernate.transaction.JBossTransactionManagerLookup"/>
- </properties>
- </persistence-unit>
-
+<persistence version="1.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_1_0.xsd">
+ <persistence-unit name="exampleDatabase"
+ transaction-type="RESOURCE_LOCAL">
+ <provider>org.hibernate.ejb.HibernatePersistence</provider>
+ <non-jta-data-source>java:comp/env/jdbc/DS</non-jta-data-source>
+ <properties>
+ <property name="hibernate.dialect"
+ value="org.hibernate.dialect.HSQLDialect" />
+ <property name="hibernate.hbm2ddl.auto" value="create" />
+ </properties>
+
+ </persistence-unit>
+
</persistence>
Added: trunk/samples/seamIntegration/src/main/webapp/META-INF/context.xml
===================================================================
--- trunk/samples/seamIntegration/src/main/webapp/META-INF/context.xml
(rev 0)
+++ trunk/samples/seamIntegration/src/main/webapp/META-INF/context.xml 2008-06-10 01:38:06
UTC (rev 8962)
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<Context >
+
+ <!-- url: The JDBC connection url for connecting to your MySQL dB.
+ The autoReconnect=true argument to the url makes sure that the
+ mm.mysql JDBC Driver will automatically reconnect if mysqld closed the
+ connection. mysqld by default closes idle connections after 8 hours.
+ -->
+
+ <Resource name="jdbc/DS" auth="Container"
+ type="javax.sql.DataSource" username="sa" password=""
+ driverClassName="org.hsqldb.jdbcDriver" url="jdbc:hsqldb:." />
+ <!--
+ <Transaction factory="org.objectweb.jotm.UserTransactionFactory"
+ jotm.timeout="60"/>
+ -->
+</Context>
\ No newline at end of file
Property changes on: trunk/samples/seamIntegration/src/main/webapp/META-INF/context.xml
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: trunk/samples/seamIntegration/src/main/webapp/WEB-INF/jetty-env.xml
===================================================================
--- trunk/samples/seamIntegration/src/main/webapp/WEB-INF/jetty-env.xml
(rev 0)
+++ trunk/samples/seamIntegration/src/main/webapp/WEB-INF/jetty-env.xml 2008-06-10
01:38:06 UTC (rev 8962)
@@ -0,0 +1,48 @@
+<?xml version="1.0"?>
+<!DOCTYPE Configure PUBLIC "-//Mort Bay Consulting//DTD Configure//EN"
"http://jetty.mortbay.org/configure.dtd">
+
+<Configure class="org.mortbay.jetty.webapp.WebAppContext">
+ <!--
+ Configure a Jotm instance which provides a javax.transaction.TransactionManager
+ and a javax.transaction.UserTransaction implementation.
+ <New id="jotm" class="org.objectweb.jotm.Jotm">
+ <Arg type="boolean">True</Arg>
+ <Arg type="boolean">False</Arg>
+ <Call id="tm" name="getTransactionManager" />
+ <Call id="ut" name="getUserTransaction" />
+ </New>
+ Set up the UserTransaction impl from JOTM as the transaction manager for jetty6
+ <New class="org.mortbay.jetty.plus.naming.Resource">
+ <Arg>TransactionManager</Arg>
+ <Arg>
+ <Ref id="tm" />
+ </Arg>
+ </New>
+ <New id="tx"
class="org.mortbay.jetty.plus.naming.Transaction">
+ <Arg>
+ <Ref id="ut" />
+ </Arg>
+ </New>
+
+ --><!-- Add a DataSource only valid for this webapp -->
+ <New id="mydatasource"
+ class="org.mortbay.jetty.plus.naming.Resource">
+ <Arg>jdbc/DS</Arg>
+ <Arg>
+ <New class="org.apache.commons.dbcp.BasicDataSource">
+ <Set name="driverClassName">org.hsqldb.jdbcDriver</Set>
+ <Set name="url">jdbc:hsqldb:.</Set>
+ <Set name="username">sa</Set>
+ <Set name="password"></Set>
+ <!--
+ <Set name="transactionManager">
+ <Ref id="tm" />
+ </Set>
+ <Set name="transactionManagerName">
+ TransactionManager
+ </Set>
+ -->
+ </New>
+ </Arg>
+ </New>
+</Configure>
Property changes on: trunk/samples/seamIntegration/src/main/webapp/WEB-INF/jetty-env.xml
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Modified: trunk/samples/seamIntegration/src/main/webapp/pages/repeater.xhtml
===================================================================
--- trunk/samples/seamIntegration/src/main/webapp/pages/repeater.xhtml 2008-06-09 23:42:04
UTC (rev 8961)
+++ trunk/samples/seamIntegration/src/main/webapp/pages/repeater.xhtml 2008-06-10 01:38:06
UTC (rev 8962)
@@ -30,7 +30,8 @@
<h2>Non-Ajax conversation</h2>
<h:commandButton action="#{seamBean.start}" value="Start
conversation" reRender="out,conversation"></h:commandButton>
<h:commandButton action="#{seamBean.stop}" value="Stop
conversation" reRender="out,conversation"></h:commandButton>
- <h:commandButton value="Refresh"
reRender="out,conversation"></h:commandButton>
+ <h:commandButton value="Refresh" ></h:commandButton>
+ <h:commandButton value="Reference to non-existed action"
action="#{seamBean.delete}"></h:commandButton>
</h:form>
<a4j:log hotkey="M"></a4j:log>
</body>