geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hogst...@apache.org
Subject svn commit: r293214 [1/4] - in /geronimo/trunk/sandbox/daytrader: ./ modules/ear/ modules/ear/src/META-INF/ modules/ear/src/application/ modules/ear/src/conf/ modules/ear/src/test-cactus/ modules/ear/src/webapp2/ modules/ear/target/ modules/ejb/src/MET...
Date Mon, 03 Oct 2005 02:35:08 GMT
Author: hogstrom
Date: Sun Oct  2 19:34:49 2005
New Revision: 293214

URL: http://svn.apache.org/viewcvs?rev=293214&view=rev
Log:
Updates to maven scripts and directory structure for day trader

Added:
    geronimo/trunk/sandbox/daytrader/modules/ear/src/META-INF/
      - copied from r292905, geronimo/trunk/sandbox/daytrader/modules/ear/src/application/META-INF/
    geronimo/trunk/sandbox/daytrader/modules/ear/src/META-INF/application.xml
      - copied unchanged from r293212, geronimo/trunk/sandbox/daytrader/modules/ear/src/application/META-INF/application.xml
    geronimo/trunk/sandbox/daytrader/modules/ejb/src/META-INF/
    geronimo/trunk/sandbox/daytrader/modules/ejb/src/META-INF/ejb-jar.xml   (with props)
    geronimo/trunk/sandbox/daytrader/modules/streamer/src/client/
    geronimo/trunk/sandbox/daytrader/modules/streamer/src/client/META-INF/
    geronimo/trunk/sandbox/daytrader/modules/streamer/src/client/META-INF/MANIFEST.MF
    geronimo/trunk/sandbox/daytrader/modules/streamer/src/client/META-INF/application-client.xml   (with props)
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/OrdersAlertFilter.java   (with props)
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/TestServlet.java   (with props)
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/TradeAppServlet.java   (with props)
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/TradeBuildDB.java   (with props)
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/TradeConfigServlet.java   (with props)
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/TradeScenarioServlet.java   (with props)
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/TradeServletAction.java   (with props)
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/TradeWebContextListener.java   (with props)
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/prims/
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/prims/PingBean.java   (with props)
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/prims/PingJDBCRead.java   (with props)
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/prims/PingJDBCWrite.java   (with props)
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/prims/PingServlet.java   (with props)
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/prims/PingServlet2EntityLocal.java   (with props)
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/prims/PingServlet2EntityRemote.java   (with props)
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/prims/PingServlet2Include.java   (with props)
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/prims/PingServlet2IncludeRcv.java   (with props)
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/prims/PingServlet2JNDI.java   (with props)
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/prims/PingServlet2Jsp.java   (with props)
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/prims/PingServlet2MDBQueue.java   (with props)
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/prims/PingServlet2MDBTopic.java   (with props)
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/prims/PingServlet2Servlet.java   (with props)
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/prims/PingServlet2ServletRcv.java   (with props)
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/prims/PingServlet2Session.java   (with props)
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/prims/PingServlet2Session2CMROne2Many.java   (with props)
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/prims/PingServlet2Session2CMROne2One.java   (with props)
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/prims/PingServlet2Session2Entity.java   (with props)
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/prims/PingServlet2Session2EntityCollection.java   (with props)
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/prims/PingServlet2TwoPhase.java   (with props)
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/prims/PingServletWriter.java   (with props)
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/prims/PingSession1.java   (with props)
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/prims/PingSession2.java   (with props)
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/prims/PingSession3.java   (with props)
    geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/prims/PingSession3Object.java   (with props)
Removed:
    geronimo/trunk/sandbox/daytrader/modules/ear/src/application/
    geronimo/trunk/sandbox/daytrader/modules/ear/src/conf/
    geronimo/trunk/sandbox/daytrader/modules/ear/src/test-cactus/
    geronimo/trunk/sandbox/daytrader/modules/ear/src/webapp2/
    geronimo/trunk/sandbox/daytrader/modules/ear/target/
    geronimo/trunk/sandbox/daytrader/modules/ejb/src/java/example/
    geronimo/trunk/sandbox/daytrader/modules/ejb/src/test-cactus/
    geronimo/trunk/sandbox/daytrader/modules/streamer/src/conf/
    geronimo/trunk/sandbox/daytrader/modules/streamer/target/
    geronimo/trunk/sandbox/daytrader/modules/web/src/conf/
    geronimo/trunk/sandbox/daytrader/modules/web/target/
Modified:
    geronimo/trunk/sandbox/daytrader/maven.xml
    geronimo/trunk/sandbox/daytrader/modules/ear/project.properties
    geronimo/trunk/sandbox/daytrader/modules/ear/project.xml
    geronimo/trunk/sandbox/daytrader/project.properties

Modified: geronimo/trunk/sandbox/daytrader/maven.xml
URL: http://svn.apache.org/viewcvs/geronimo/trunk/sandbox/daytrader/maven.xml?rev=293214&r1=293213&r2=293214&view=diff
==============================================================================
--- geronimo/trunk/sandbox/daytrader/maven.xml (original)
+++ geronimo/trunk/sandbox/daytrader/maven.xml Sun Oct  2 19:34:49 2005
@@ -1,10 +1,24 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <project xmlns:j="jelly:core" xmlns:ant="jelly:ant" xmlns:maven="jelly:maven" default="multiproject:build">
   <goal name="multiproject:build">
+    <attainGoal name="multiproject:jar-install" />
     <attainGoal name="multiproject:ejb-install" />
+    <attainGoal name="multiproject:streamer-install" />
     <attainGoal name="multiproject:war-install" />
     <attainGoal name="multiproject:ear" />
   </goal>
+  <goal name="multiproject:clean">
+   <maven:reactor
+      basedir="."
+      banner="Cleaning"
+      includes="${maven.multiproject.includes}"
+      excludes="${maven.multiproject.excludes}"
+      postProcessing="true"
+      goals="clean"
+      ignoreFailures="${maven.multiproject.ignoreFailures}"
+    />
+  </goal>
+  
   <goal name="multiproject:war">
     <maven:reactor
       basedir="."
@@ -38,6 +52,28 @@
       ignoreFailures="${maven.multiproject.ignoreFailures}"
     />
   </goal>
+    <goal name="multiproject:jar-install">
+    <maven:reactor
+      basedir="."
+      banner="Creating JARs"
+      includes="${maven.multiproject.jar.includes}"
+      excludes="${maven.multiproject.jar.excludes}"
+      postProcessing="true"
+      goals="jar:install"
+      ignoreFailures="${maven.multiproject.ignoreFailures}"
+    />
+    </goal>
+    <goal name="multiproject:streamer-install">
+    <maven:reactor
+      basedir="."
+      banner="Creating Streamer Application Client"
+      includes="${maven.multiproject.streamer.includes}"
+      excludes="${maven.multiproject.streamer.excludes}"
+      postProcessing="true"
+      goals="jar:install"
+      ignoreFailures="${maven.multiproject.ignoreFailures}"
+    />
+    </goal>
   <goal name="multiproject:war-install">
     <maven:reactor
       basedir="."

Modified: geronimo/trunk/sandbox/daytrader/modules/ear/project.properties
URL: http://svn.apache.org/viewcvs/geronimo/trunk/sandbox/daytrader/modules/ear/project.properties?rev=293214&r1=293213&r2=293214&view=diff
==============================================================================
--- geronimo/trunk/sandbox/daytrader/modules/ear/project.properties (original)
+++ geronimo/trunk/sandbox/daytrader/modules/ear/project.properties Sun Oct  2 19:34:49 2005
@@ -1,11 +1 @@
-maven.xdoc.date=left
-maven.ejb.src=${maven.build.dir}/xdoclet/ejb
-maven.eclipse.classpath.include=${maven.build.dir}/xdoclet/ejbdoclet,src/test-cactus
-maven.xdoclet.ejbdoclet.utilobject.0.cacheHomes=true
-maven.xdoclet.ejbdoclet.utilobject.0.includeGUID=true
-maven.xdoclet.ejbdoclet.dataobject.0=true
-maven.xdoclet.ejbdoclet.entityfacade.0=true
-maven.xdoclet.ejbdoclet.valueobject.0=true
-maven.xdoclet.ejbdoclet.deploymentdescriptor.0.validateXML=true
-cactus.src.mergewebxml = src/conf/cactus-web.xml
-cactus.is.ear=true
+maven.ear.appxml=${maven.ear.src}/META-INF/application.xml

Modified: geronimo/trunk/sandbox/daytrader/modules/ear/project.xml
URL: http://svn.apache.org/viewcvs/geronimo/trunk/sandbox/daytrader/modules/ear/project.xml?rev=293214&r1=293213&r2=293214&view=diff
==============================================================================
--- geronimo/trunk/sandbox/daytrader/modules/ear/project.xml (original)
+++ geronimo/trunk/sandbox/daytrader/modules/ear/project.xml Sun Oct  2 19:34:49 2005
@@ -52,11 +52,6 @@
           <ear.bundle>true</ear.bundle>
       </properties>
     </dependency>
-<!--    <dependency>
-      <groupId>geronimo-spec</groupId>
-      <artifactId>geronimo-spec-j2ee</artifactId>
-      <version>1.4-rc4</version>
-    </dependency> -->
     
   </dependencies>
   <build>
@@ -71,12 +66,6 @@
       </excludes>
     </unitTest>
     <resources>
-        <resource>
-            <directory>src/application</directory>
-            <includes>
-                <include>META-INF/application-client.xml</include>
-            </includes>
-        </resource>
     </resources>
   </build>
 </project>

Added: geronimo/trunk/sandbox/daytrader/modules/ejb/src/META-INF/ejb-jar.xml
URL: http://svn.apache.org/viewcvs/geronimo/trunk/sandbox/daytrader/modules/ejb/src/META-INF/ejb-jar.xml?rev=293214&view=auto
==============================================================================
--- geronimo/trunk/sandbox/daytrader/modules/ejb/src/META-INF/ejb-jar.xml (added)
+++ geronimo/trunk/sandbox/daytrader/modules/ejb/src/META-INF/ejb-jar.xml Sun Oct  2 19:34:49 2005
@@ -0,0 +1,937 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<ejb-jar version="2.1"
+    xmlns="http://java.sun.com/xml/ns/j2ee"
+    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/ejb-jar_2_1.xsd"> 
+    <display-name>TradeEJBs</display-name>
+    <enterprise-beans>
+        <session>
+            <description>Trade Session EJB manages all Trading services</description>
+            <display-name>TradeEJB</display-name>
+            <ejb-name>TradeEJB</ejb-name>
+            <home>org.apache.geronimo.samples.daytrader.ejb.TradeHome</home>
+            <remote>org.apache.geronimo.samples.daytrader.ejb.Trade</remote>
+            <ejb-class>org.apache.geronimo.samples.daytrader.ejb.TradeBean</ejb-class>
+            <session-type>Stateless</session-type>
+            <transaction-type>Container</transaction-type>
+            <env-entry>
+                <env-entry-name>orderBySQLSupported</env-entry-name>
+                <env-entry-type>java.lang.Boolean</env-entry-type>
+                <env-entry-value>true</env-entry-value>
+            </env-entry>
+            <env-entry>
+                <env-entry-name>updateQuotePrices</env-entry-name>
+                <env-entry-type>java.lang.Boolean</env-entry-type>
+                <env-entry-value>true</env-entry-value>
+            </env-entry>
+            <env-entry>
+                <env-entry-name>publishQuotePriceChange</env-entry-name>
+                <env-entry-type>java.lang.Boolean</env-entry-type>
+                <env-entry-value>true</env-entry-value>
+            </env-entry>
+            <ejb-ref>
+                <ejb-ref-name>ejb/Trade</ejb-ref-name>
+                <ejb-ref-type>Session</ejb-ref-type>
+                <home>org.apache.geronimo.samples.daytrader.ejb.TradeHome</home>
+                <remote>org.apache.geronimo.samples.daytrader.ejb.Trade</remote>
+                <ejb-link>TradeEJB</ejb-link>
+            </ejb-ref>
+            <ejb-local-ref>
+                <ejb-ref-name>ejb/Quote</ejb-ref-name>
+                <ejb-ref-type>Entity</ejb-ref-type>
+                <local-home>org.apache.geronimo.samples.daytrader.ejb.LocalQuoteHome</local-home>
+                <local>org.apache.geronimo.samples.daytrader.ejb.LocalQuote</local>
+                <ejb-link>QuoteEJB</ejb-link>
+            </ejb-local-ref>
+            <ejb-local-ref>
+                <ejb-ref-name>ejb/Account</ejb-ref-name>
+                <ejb-ref-type>Entity</ejb-ref-type>
+                <local-home>org.apache.geronimo.samples.daytrader.ejb.LocalAccountHome</local-home>
+                <local>org.apache.geronimo.samples.daytrader.ejb.LocalAccount</local>
+                <ejb-link>AccountEJB</ejb-link>
+            </ejb-local-ref>
+            <ejb-local-ref>
+                <ejb-ref-name>ejb/Holding</ejb-ref-name>
+                <ejb-ref-type>Entity</ejb-ref-type>
+                <local-home>org.apache.geronimo.samples.daytrader.ejb.LocalHoldingHome</local-home>
+                <local>org.apache.geronimo.samples.daytrader.ejb.LocalHolding</local>
+                <ejb-link>HoldingEJB</ejb-link>
+            </ejb-local-ref>
+            <ejb-local-ref>
+                <ejb-ref-name>ejb/Order</ejb-ref-name>
+                <ejb-ref-type>Entity</ejb-ref-type>
+                <local-home>org.apache.geronimo.samples.daytrader.ejb.LocalOrderHome</local-home>
+                <local>org.apache.geronimo.samples.daytrader.ejb.LocalOrder</local>
+                <ejb-link>OrderEJB</ejb-link>
+            </ejb-local-ref>
+            <ejb-local-ref>
+                <ejb-ref-name>ejb/KeySequence</ejb-ref-name>
+                <ejb-ref-type>Session</ejb-ref-type>
+                <local-home>org.apache.geronimo.samples.daytrader.ejb.LocalKeySequenceHome</local-home>
+                <local>org.apache.geronimo.samples.daytrader.ejb.LocalKeySequence</local>
+                <ejb-link>KeySequenceEJB</ejb-link>
+            </ejb-local-ref>
+            <ejb-local-ref>
+                <ejb-ref-name>ejb/AccountProfile</ejb-ref-name>
+                <ejb-ref-type>Entity</ejb-ref-type>
+                <local-home>org.apache.geronimo.samples.daytrader.ejb.LocalAccountProfileHome</local-home>
+                <local>org.apache.geronimo.samples.daytrader.ejb.LocalAccountProfile</local>
+                <ejb-link>AccountProfileEJB</ejb-link>
+            </ejb-local-ref>
+            <resource-ref>
+                <res-ref-name>jms/QueueConnectionFactory</res-ref-name>
+                <res-type>javax.jms.QueueConnectionFactory</res-type>
+                <res-auth>Application</res-auth>
+                <res-sharing-scope>Shareable</res-sharing-scope>
+            </resource-ref>
+            <resource-ref>
+                <res-ref-name>jms/TopicConnectionFactory</res-ref-name>
+                <res-type>javax.jms.TopicConnectionFactory</res-type>
+                <res-auth>Application</res-auth>
+                <res-sharing-scope>Shareable</res-sharing-scope>
+            </resource-ref>
+            <resource-ref>
+                <res-ref-name>jdbc/TradeDataSource</res-ref-name>
+                <res-type>javax.sql.DataSource</res-type>
+                <res-auth>Container</res-auth>
+                <res-sharing-scope>Shareable</res-sharing-scope>
+            </resource-ref>
+            <message-destination-ref>
+                <message-destination-ref-name>jms/TradeBrokerQueue</message-destination-ref-name>
+                <message-destination-type>javax.jms.Queue</message-destination-type>
+                <message-destination-usage>Produces</message-destination-usage>
+                <message-destination-link>TradeBrokerQueue</message-destination-link>
+            </message-destination-ref>
+            <message-destination-ref>
+                <message-destination-ref-name>jms/TradeStreamerTopic</message-destination-ref-name>
+                <message-destination-type>javax.jms.Topic</message-destination-type>
+                <message-destination-usage>Produces</message-destination-usage>
+                <message-destination-link>TradeStreamerTopic</message-destination-link>
+            </message-destination-ref>
+            <security-identity>
+                <description/>
+                <use-caller-identity/>
+            </security-identity>
+        </session>
+        <entity>
+            <display-name>HoldingEJB</display-name>
+            <ejb-name>HoldingEJB</ejb-name>
+            <local-home>org.apache.geronimo.samples.daytrader.ejb.LocalHoldingHome</local-home>
+            <local>org.apache.geronimo.samples.daytrader.ejb.LocalHolding</local>
+            <ejb-class>org.apache.geronimo.samples.daytrader.ejb.HoldingBean</ejb-class>
+            <persistence-type>Container</persistence-type>
+            <prim-key-class>java.lang.Integer</prim-key-class>
+            <reentrant>false</reentrant>
+            <cmp-version>2.x</cmp-version>
+            <abstract-schema-name>Holding</abstract-schema-name>
+            <cmp-field>
+                <field-name>purchasePrice</field-name>
+            </cmp-field>
+            <cmp-field>
+                <field-name>holdingID</field-name>
+            </cmp-field>
+            <cmp-field>
+                <field-name>quantity</field-name>
+            </cmp-field>
+            <cmp-field>
+                <field-name>purchaseDate</field-name>
+            </cmp-field>
+            <primkey-field>holdingID</primkey-field>
+            <security-identity>
+                <description/>
+                <use-caller-identity/>
+            </security-identity>
+            <query>
+                <description/>
+                <query-method>
+                    <method-name>ejbSelectQuoteFromSymbol</method-name>
+                    <method-params>
+                        <method-param>java.lang.String</method-param>
+                    </method-params>
+                </query-method>
+                <result-type-mapping>Local</result-type-mapping>
+                <ejb-ql>SELECT OBJECT(q) from Quote q WHERE q.symbol = ?1</ejb-ql>
+            </query>
+            <query>
+                <description/>
+                <query-method>
+                    <method-name>findAll</method-name>
+                    <method-params/>
+                </query-method>
+                <result-type-mapping>Local</result-type-mapping>
+                <ejb-ql>SELECT OBJECT(h) from Holding h</ejb-ql>
+            </query>
+            <query>
+                <description/>
+                <query-method>
+                    <method-name>findByUserID</method-name>
+                    <method-params>
+                        <method-param>java.lang.String</method-param>
+                    </method-params>
+                </query-method>
+                <result-type-mapping>Local</result-type-mapping>
+                <ejb-ql>SELECT OBJECT(h) FROM Holding h WHERE
+                    h.account.profile.userID  = ?1</ejb-ql>
+            </query>
+            <query>
+                <description/>
+                <query-method>
+                    <method-name>findByAccountID</method-name>
+                    <method-params>
+                        <method-param>java.lang.Integer</method-param>
+                    </method-params>
+                </query-method>
+                <result-type-mapping>Local</result-type-mapping>
+                <ejb-ql>SELECT OBJECT(h) FROM Holding h WHERE
+                    h.account.accountID  = ?1</ejb-ql>
+            </query>
+            <query>
+                <query-method>
+                    <method-name>findByPrimaryKeyForUpdate</method-name>
+                    <method-params>
+                        <method-param>java.lang.Integer</method-param>
+                    </method-params>
+                </query-method>
+                <result-type-mapping>Local</result-type-mapping>
+                <ejb-ql>SELECT OBJECT(h) FROM Holding h WHERE
+                    h.holdingID = ?1</ejb-ql>
+            </query>
+        </entity>
+        <message-driven>
+            <display-name>TradeBrokerMDB</display-name>
+            <ejb-name>TradeBrokerMDB</ejb-name>
+            <ejb-class>org.apache.geronimo.samples.daytrader.ejb.TradeBrokerMDB</ejb-class>
+            <transaction-type>Container</transaction-type>
+            <message-destination-type>javax.jms.Queue</message-destination-type>
+            <message-destination-link>TradeBrokerQueue</message-destination-link>
+            <env-entry>
+                <env-entry-name>statInterval</env-entry-name>
+                <env-entry-type>java.lang.Integer</env-entry-type>
+                <env-entry-value>100</env-entry-value>
+            </env-entry>
+            <ejb-ref>
+                <ejb-ref-name>ejb/Trade</ejb-ref-name>
+                <ejb-ref-type>Session</ejb-ref-type>
+                <home>org.apache.geronimo.samples.daytrader.ejb.TradeHome</home>
+                <remote>org.apache.geronimo.samples.daytrader.ejb.Trade</remote>
+                <ejb-link>TradeEJB</ejb-link>
+            </ejb-ref>
+        </message-driven>
+        <entity>
+            <display-name>AccountProfileEJB</display-name>
+            <ejb-name>AccountProfileEJB</ejb-name>
+            <local-home>org.apache.geronimo.samples.daytrader.ejb.LocalAccountProfileHome</local-home>
+            <local>org.apache.geronimo.samples.daytrader.ejb.LocalAccountProfile</local>
+            <ejb-class>org.apache.geronimo.samples.daytrader.ejb.AccountProfileBean</ejb-class>
+            <persistence-type>Container</persistence-type>
+            <prim-key-class>java.lang.String</prim-key-class>
+            <reentrant>false</reentrant>
+            <cmp-version>2.x</cmp-version>
+            <abstract-schema-name>AccountProfile</abstract-schema-name>
+            <cmp-field>
+                <field-name>address</field-name>
+            </cmp-field>
+            <cmp-field>
+                <field-name>password</field-name>
+            </cmp-field>
+            <cmp-field>
+                <field-name>userID</field-name>
+            </cmp-field>
+            <cmp-field>
+                <field-name>email</field-name>
+            </cmp-field>
+            <cmp-field>
+                <field-name>creditCard</field-name>
+            </cmp-field>
+            <cmp-field>
+                <field-name>fullName</field-name>
+            </cmp-field>
+            <primkey-field>userID</primkey-field>
+            <security-identity>
+                <description/>
+                <use-caller-identity/>
+            </security-identity>
+            <query id="Query_5">
+                <description/>
+                <query-method>
+                    <method-name>findAll</method-name>
+                    <method-params/>
+                </query-method>
+                <result-type-mapping>Local</result-type-mapping>
+                <ejb-ql>SELECT OBJECT(a) FROM AccountProfile a</ejb-ql>
+            </query>
+            <query>
+                <description/>
+                <query-method>
+                    <method-name>findByPrimaryKeyForUpdate</method-name>
+                    <method-params>
+                        <method-param>java.lang.String</method-param>
+                    </method-params>
+                </query-method>
+                <result-type-mapping>Local</result-type-mapping>
+                <ejb-ql>SELECT OBJECT(a) FROM AccountProfile a where
+                    a.userID = ?1</ejb-ql>
+            </query>
+        </entity>
+        <entity>
+            <description>Stock price quotes including current, open, high, low, etc.</description>
+            <display-name>QuoteEJB</display-name>
+            <ejb-name>QuoteEJB</ejb-name>
+            <home>org.apache.geronimo.samples.daytrader.ejb.QuoteHome</home>
+            <remote>org.apache.geronimo.samples.daytrader.ejb.Quote</remote>
+            <local-home>org.apache.geronimo.samples.daytrader.ejb.LocalQuoteHome</local-home>
+            <local>org.apache.geronimo.samples.daytrader.ejb.LocalQuote</local>
+            <ejb-class>org.apache.geronimo.samples.daytrader.ejb.QuoteBean</ejb-class>
+            <persistence-type>Container</persistence-type>
+            <prim-key-class>java.lang.String</prim-key-class>
+            <reentrant>false</reentrant>
+            <cmp-version>2.x</cmp-version>
+            <abstract-schema-name>Quote</abstract-schema-name>
+            <cmp-field>
+                <field-name>low</field-name>
+            </cmp-field>
+            <cmp-field>
+                <field-name>open</field-name>
+            </cmp-field>
+            <cmp-field>
+                <field-name>volume</field-name>
+            </cmp-field>
+            <cmp-field>
+                <field-name>price</field-name>
+            </cmp-field>
+            <cmp-field>
+                <field-name>high</field-name>
+            </cmp-field>
+            <cmp-field>
+                <field-name>companyName</field-name>
+            </cmp-field>
+            <cmp-field>
+                <field-name>symbol</field-name>
+            </cmp-field>
+            <cmp-field>
+                <field-name>change</field-name>
+            </cmp-field>
+            <primkey-field>symbol</primkey-field>
+            <security-identity>
+                <description/>
+                <use-caller-identity/>
+            </security-identity>
+            <query id="Query_6">
+                <description/>
+                <query-method>
+                    <method-name>findAll</method-name>
+                    <method-params/>
+                </query-method>
+                <result-type-mapping>Local</result-type-mapping>
+                <ejb-ql>SELECT OBJECT(q) FROM Quote q</ejb-ql>
+            </query>
+            <query>
+                <description/>
+                <query-method>
+                    <method-name>findQuotes</method-name>
+                    <method-params>
+                        <method-param>java.lang.String</method-param>
+                    </method-params>
+                </query-method>
+                <result-type-mapping>Local</result-type-mapping>
+                <ejb-ql>SELECT OBJECT(q) FROM Quote q</ejb-ql>
+            </query>
+            <query>
+                <description/>
+                <query-method>
+                    <method-name>findOne</method-name>
+                    <method-params/>
+                </query-method>
+                <result-type-mapping>Local</result-type-mapping>
+                <ejb-ql>SELECT OBJECT(q) FROM Quote q where q.symbol = 's:0'</ejb-ql>
+            </query>
+            <query>
+                <query-method>
+                    <method-name>findTSIAQuotesOrderByChange</method-name>
+                    <method-params/>
+                </query-method>
+                <result-type-mapping>Local</result-type-mapping>
+                <ejb-ql>SELECT OBJECT(q) FROM Quote q WHERE q.symbol LIKE 's:1__' ORDER BY q.change DESC</ejb-ql>
+            </query>
+            <query id="Query_10">
+                <description/>
+                <query-method>
+                    <method-name>ejbSelectTotalVolume</method-name>
+                    <method-params/>
+                </query-method>
+                <result-type-mapping>Local</result-type-mapping>
+                <ejb-ql>SELECT q.volume FROM Quote q</ejb-ql>
+            </query>
+            <query>
+                <query-method>
+                    <method-name>findTSIAQuotes</method-name>
+                    <method-params/>
+                </query-method>
+                <result-type-mapping>Local</result-type-mapping>
+                <ejb-ql>SELECT OBJECT(q) FROM Quote q WHERE q.symbol LIKE 's:1__'</ejb-ql>
+            </query>
+            <query>
+                <query-method id="QueryMethod_21">
+                    <method-name>findByPrimaryKeyForUpdate</method-name>
+                    <method-params>
+                        <method-param>java.lang.String</method-param>
+                    </method-params>
+                </query-method>
+                <result-type-mapping>Local</result-type-mapping>
+                <ejb-ql>SELECT OBJECT(q) FROM Quote q where q.symbol = ?1</ejb-ql>
+            </query>
+        </entity>
+        <session>
+            <display-name>KeySequenceEJB</display-name>
+            <ejb-name>KeySequenceEJB</ejb-name>
+            <local-home>org.apache.geronimo.samples.daytrader.ejb.LocalKeySequenceHome</local-home>
+            <local>org.apache.geronimo.samples.daytrader.ejb.LocalKeySequence</local>
+            <ejb-class>org.apache.geronimo.samples.daytrader.ejb.KeySequenceBean</ejb-class>
+            <session-type>Stateless</session-type>
+            <transaction-type>Container</transaction-type>
+            <ejb-local-ref>
+                <ejb-ref-name>ejb/KeyGen</ejb-ref-name>
+                <ejb-ref-type>Entity</ejb-ref-type>
+                <local-home>org.apache.geronimo.samples.daytrader.ejb.LocalKeyGenHome</local-home>
+                <local>org.apache.geronimo.samples.daytrader.ejb.LocalKeyGen</local>
+                <ejb-link>KeyGenEJB</ejb-link>
+            </ejb-local-ref>
+            <security-identity>
+                <description/>
+                <use-caller-identity/>
+            </security-identity>
+        </session>
+        <entity>
+            <display-name>KeyGenEJB</display-name>
+            <ejb-name>KeyGenEJB</ejb-name>
+            <local-home>org.apache.geronimo.samples.daytrader.ejb.LocalKeyGenHome</local-home>
+            <local>org.apache.geronimo.samples.daytrader.ejb.LocalKeyGen</local>
+            <ejb-class>org.apache.geronimo.samples.daytrader.ejb.KeyGenBean</ejb-class>
+            <persistence-type>Container</persistence-type>
+            <prim-key-class>java.lang.String</prim-key-class>
+            <reentrant>false</reentrant>
+            <cmp-version>2.x</cmp-version>
+            <abstract-schema-name>KeyGen</abstract-schema-name>
+            <cmp-field>
+                <field-name>keyVal</field-name>
+            </cmp-field>
+            <cmp-field>
+                <field-name>keyName</field-name>
+            </cmp-field>
+            <primkey-field>keyName</primkey-field>
+            <security-identity>
+                <description/>
+                <use-caller-identity/>
+            </security-identity>
+            <query>
+                <query-method>
+                    <method-name>findByPrimaryKeyForUpdate</method-name>
+                    <method-params>
+                        <method-param>java.lang.String</method-param>
+                    </method-params>
+                </query-method>
+                <result-type-mapping>Local</result-type-mapping>
+                <ejb-ql>SELECT OBJECT(kg) FROM KeyGen kg where
+                    kg.keyName = ?1</ejb-ql>
+            </query>
+        </entity>
+        <entity>
+            <display-name>AccountEJB</display-name>
+            <ejb-name>AccountEJB</ejb-name>
+            <local-home>org.apache.geronimo.samples.daytrader.ejb.LocalAccountHome</local-home>
+            <local>org.apache.geronimo.samples.daytrader.ejb.LocalAccount</local>
+            <ejb-class>org.apache.geronimo.samples.daytrader.ejb.AccountBean</ejb-class>
+            <persistence-type>Container</persistence-type>
+            <prim-key-class>java.lang.Integer</prim-key-class>
+            <reentrant>false</reentrant>
+            <cmp-version>2.x</cmp-version>
+            <abstract-schema-name>Account</abstract-schema-name>
+            <cmp-field>
+                <field-name>creationDate</field-name>
+            </cmp-field>
+            <cmp-field>
+                <field-name>openBalance</field-name>
+            </cmp-field>
+            <cmp-field>
+                <field-name>logoutCount</field-name>
+            </cmp-field>
+            <cmp-field>
+                <field-name>balance</field-name>
+            </cmp-field>
+            <cmp-field>
+                <field-name>accountID</field-name>
+            </cmp-field>
+            <cmp-field>
+                <field-name>lastLogin</field-name>
+            </cmp-field>
+            <cmp-field>
+                <field-name>loginCount</field-name>
+            </cmp-field>
+            <primkey-field>accountID</primkey-field>
+            <ejb-local-ref>
+                <ejb-ref-name>ejb/AccountProfile</ejb-ref-name>
+                <ejb-ref-type>Entity</ejb-ref-type>
+                <local-home>org.apache.geronimo.samples.daytrader.ejb.LocalAccountProfileHome</local-home>
+                <local>org.apache.geronimo.samples.daytrader.ejb.LocalAccountProfile</local>
+                <ejb-link>AccountProfileEJB</ejb-link>
+            </ejb-local-ref>
+            <security-identity>
+                <description/>
+                <use-caller-identity/>
+            </security-identity>
+            <query>
+                <description/>
+                <query-method>
+                    <method-name>findByUserID</method-name>
+                    <method-params>
+                        <method-param>java.lang.String</method-param>
+                    </method-params>
+                </query-method>
+                <ejb-ql>SELECT OBJECT(a) FROM Account a WHERE
+                    a.profile.userID = ?1</ejb-ql>
+            </query>
+            <query>
+                <description/>
+                <query-method>
+                    <method-name>findAll</method-name>
+                    <method-params/>
+                </query-method>
+                <ejb-ql>SELECT OBJECT(a) FROM Account a</ejb-ql>
+            </query>
+            <query>
+                <query-method>
+                    <method-name>findByUserIDForUpdate</method-name>
+                    <method-params>
+                        <method-param>java.lang.String</method-param>
+                    </method-params>
+                </query-method>
+                <result-type-mapping>Local</result-type-mapping>
+                <ejb-ql>SELECT OBJECT(a) FROM Account a WHERE
+                    a.profile.userID = ?1</ejb-ql>
+            </query>
+            <query>
+                <query-method>
+                    <method-name>ejbSelectClosedOrders</method-name>
+                    <method-params>
+                        <method-param>java.lang.Integer</method-param>
+                    </method-params>
+                </query-method>
+                <ejb-ql>SELECT o.orderID FROM Orders o WHERE
+                    o.orderStatus = 'closed' AND o.account.accountID  = ?1</ejb-ql>
+            </query>
+            <query>
+                <query-method>
+                    <method-name>findByPrimaryKeyForUpdate</method-name>
+                    <method-params>
+                        <method-param>java.lang.Integer</method-param>
+                    </method-params>
+                </query-method>
+                <result-type-mapping>Local</result-type-mapping>
+                <ejb-ql>SELECT OBJECT(a) FROM Account a where
+                    a.accountID = ?1</ejb-ql>
+            </query>
+        </entity>
+        <entity>
+            <display-name>OrderEJB</display-name>
+            <ejb-name>OrderEJB</ejb-name>
+            <local-home>org.apache.geronimo.samples.daytrader.ejb.LocalOrderHome</local-home>
+            <local>org.apache.geronimo.samples.daytrader.ejb.LocalOrder</local>
+            <ejb-class>org.apache.geronimo.samples.daytrader.ejb.OrderBean</ejb-class>
+            <persistence-type>Container</persistence-type>
+            <prim-key-class>java.lang.Integer</prim-key-class>
+            <reentrant>false</reentrant>
+            <cmp-version>2.x</cmp-version>
+            <abstract-schema-name>Orders</abstract-schema-name>
+            <cmp-field>
+                <field-name>orderFee</field-name>
+            </cmp-field>
+            <cmp-field>
+                <field-name>completionDate</field-name>
+            </cmp-field>
+            <cmp-field>
+                <field-name>orderType</field-name>
+            </cmp-field>
+            <cmp-field>
+                <field-name>orderStatus</field-name>
+            </cmp-field>
+            <cmp-field>
+                <field-name>price</field-name>
+            </cmp-field>
+            <cmp-field>
+                <field-name>quantity</field-name>
+            </cmp-field>
+            <cmp-field>
+                <field-name>openDate</field-name>
+            </cmp-field>
+            <cmp-field>
+                <field-name>orderID</field-name>
+            </cmp-field>
+            <primkey-field>orderID</primkey-field>
+            <security-identity>
+                <description/>
+                <use-caller-identity/>
+            </security-identity>
+            <query>
+                <description/>
+                <query-method>
+                    <method-name>findAll</method-name>
+                    <method-params/>
+                </query-method>
+                <result-type-mapping>Local</result-type-mapping>
+                <ejb-ql>SELECT OBJECT(o) FROM Orders o</ejb-ql>
+            </query>
+            <query>
+                <description/>
+                <query-method>
+                    <method-name>findClosedOrders</method-name>
+                    <method-params>
+                        <method-param>java.lang.String</method-param>
+                    </method-params>
+                </query-method>
+                <result-type-mapping>Local</result-type-mapping>
+                <ejb-ql>SELECT OBJECT(o) FROM Orders o WHERE
+                    o.orderStatus = 'closed' AND
+                    o.account.profile.userID  = ?1</ejb-ql>
+            </query>
+            <query>
+                <description/>
+                <query-method>
+                    <method-name>findByUserID</method-name>
+                    <method-params>
+                        <method-param>java.lang.String</method-param>
+                    </method-params>
+                </query-method>
+                <result-type-mapping>Local</result-type-mapping>
+                <ejb-ql>SELECT OBJECT(o) FROM Orders o WHERE
+                    o.account.profile.userID  = ?1 ORDER BY o.orderID DESC</ejb-ql>
+            </query>
+            <query>
+                <query-method>
+                    <method-name>findByPrimaryKeyForUpdate</method-name>
+                    <method-params>
+                        <method-param>java.lang.Integer</method-param>
+                    </method-params>
+                </query-method>
+                <result-type-mapping>Local</result-type-mapping>
+                <ejb-ql>SELECT OBJECT(o) FROM Orders o WHERE o.orderID = ?1</ejb-ql>
+            </query>
+            <query>
+                <query-method>
+                    <method-name>findClosedOrdersForUpdate</method-name>
+                    <method-params>
+                        <method-param>java.lang.String</method-param>
+                    </method-params>
+                </query-method>
+                <result-type-mapping>Local</result-type-mapping>
+                <ejb-ql>SELECT OBJECT(o) FROM Orders o WHERE
+                    o.orderStatus = 'closed' AND
+                    o.account.profile.userID  = ?1</ejb-ql>
+            </query>
+        </entity>
+        <message-driven>
+            <ejb-name>TradeStreamerMDB</ejb-name>
+            <ejb-class>org.apache.geronimo.samples.daytrader.ejb.TradeStreamerMDB</ejb-class>
+            <transaction-type>Container</transaction-type>
+            <message-destination-type>javax.jms.Topic</message-destination-type>
+            <message-destination-link>TradeStreamerTopic</message-destination-link>
+            <env-entry>
+                <env-entry-name>statInterval</env-entry-name>
+                <env-entry-type>java.lang.Integer</env-entry-type>
+                <env-entry-value>100</env-entry-value>
+            </env-entry>
+        </message-driven>
+    </enterprise-beans>
+    <relationships>
+        <ejb-relation>
+            <ejb-relation-name>Account-Orders</ejb-relation-name>
+            <ejb-relationship-role>
+                <ejb-relationship-role-name>AccountEJB</ejb-relationship-role-name>
+                <multiplicity>One</multiplicity>
+                <relationship-role-source>
+                    <ejb-name>AccountEJB</ejb-name>
+                </relationship-role-source>
+                <cmr-field>
+                    <cmr-field-name>orders</cmr-field-name>
+                    <cmr-field-type>java.util.Collection</cmr-field-type>
+                </cmr-field>
+            </ejb-relationship-role>
+            <ejb-relationship-role>
+                <ejb-relationship-role-name>Order-Has-Account</ejb-relationship-role-name>
+                <multiplicity>Many</multiplicity>
+                <cascade-delete/>
+                <relationship-role-source>
+                    <ejb-name>OrderEJB</ejb-name>
+                </relationship-role-source>
+                <cmr-field>
+                    <cmr-field-name>account</cmr-field-name>
+                </cmr-field>
+            </ejb-relationship-role>
+        </ejb-relation>
+        <ejb-relation>
+            <ejb-relation-name>Account-AccountProfile</ejb-relation-name>
+            <ejb-relationship-role>
+                <ejb-relationship-role-name>Account-Has-AccountProfile</ejb-relationship-role-name>
+                <multiplicity>One</multiplicity>
+                <relationship-role-source>
+                    <ejb-name>AccountEJB</ejb-name>
+                </relationship-role-source>
+                <cmr-field>
+                    <cmr-field-name>profile</cmr-field-name>
+                </cmr-field>
+            </ejb-relationship-role>
+            <ejb-relationship-role>
+                <ejb-relationship-role-name>AccountProfileEJB</ejb-relationship-role-name>
+                <multiplicity>One</multiplicity>
+                <cascade-delete/>
+                <relationship-role-source>
+                    <ejb-name>AccountProfileEJB</ejb-name>
+                </relationship-role-source>
+                <cmr-field>
+                    <cmr-field-name>account</cmr-field-name>
+                </cmr-field>
+            </ejb-relationship-role>
+        </ejb-relation>
+        <ejb-relation>
+            <ejb-relation-name>Account-Holdings</ejb-relation-name>
+            <ejb-relationship-role>
+                <ejb-relationship-role-name>AccountEJB</ejb-relationship-role-name>
+                <multiplicity>One</multiplicity>
+                <relationship-role-source>
+                    <ejb-name>AccountEJB</ejb-name>
+                </relationship-role-source>
+                <cmr-field>
+                    <cmr-field-name>holdings</cmr-field-name>
+                    <cmr-field-type>java.util.Collection</cmr-field-type>
+                </cmr-field>
+            </ejb-relationship-role>
+            <ejb-relationship-role>
+                <ejb-relationship-role-name>Holding-Has-Account</ejb-relationship-role-name>
+                <multiplicity>Many</multiplicity>
+                <cascade-delete/>
+                <relationship-role-source>
+                    <ejb-name>HoldingEJB</ejb-name>
+                </relationship-role-source>
+                <cmr-field>
+                    <cmr-field-name>account</cmr-field-name>
+                </cmr-field>
+            </ejb-relationship-role>
+        </ejb-relation>
+        <ejb-relation>
+            <ejb-relation-name>Quote-Holdings</ejb-relation-name>
+            <ejb-relationship-role>
+                <ejb-relationship-role-name>Holding-Has-Quote</ejb-relationship-role-name>
+                <multiplicity>Many</multiplicity>
+                <relationship-role-source>
+                    <ejb-name>HoldingEJB</ejb-name>
+                </relationship-role-source>
+                <cmr-field>
+                    <cmr-field-name>quote</cmr-field-name>
+                </cmr-field>
+            </ejb-relationship-role>
+            <ejb-relationship-role>
+                <ejb-relationship-role-name>QuoteEJB</ejb-relationship-role-name>
+                <multiplicity>One</multiplicity>
+                <relationship-role-source>
+                    <ejb-name>QuoteEJB</ejb-name>
+                </relationship-role-source>
+            </ejb-relationship-role>
+        </ejb-relation>
+        <ejb-relation>
+            <ejb-relation-name>Quote-Orders</ejb-relation-name>
+            <ejb-relationship-role>
+                <ejb-relationship-role-name>Order-Has-Quote</ejb-relationship-role-name>
+                <multiplicity>Many</multiplicity>
+                <cascade-delete/>
+                <relationship-role-source>
+                    <ejb-name>OrderEJB</ejb-name>
+                </relationship-role-source>
+                <cmr-field>
+                    <cmr-field-name>quote</cmr-field-name>
+                </cmr-field>
+            </ejb-relationship-role>
+            <ejb-relationship-role>
+                <ejb-relationship-role-name>QuoteEJB</ejb-relationship-role-name>
+                <multiplicity>One</multiplicity>
+                <relationship-role-source>
+                    <ejb-name>QuoteEJB</ejb-name>
+                </relationship-role-source>
+                <cmr-field>
+                    <cmr-field-name>orders</cmr-field-name>
+                    <cmr-field-type>java.util.Collection</cmr-field-type>
+                </cmr-field>
+            </ejb-relationship-role>
+        </ejb-relation>
+        <ejb-relation>
+            <ejb-relation-name>Order-Holding</ejb-relation-name>
+            <ejb-relationship-role>
+                <ejb-relationship-role-name>Order-Has-Holding</ejb-relationship-role-name>
+                <multiplicity>One</multiplicity>
+                <relationship-role-source>
+                    <ejb-name>OrderEJB</ejb-name>
+                </relationship-role-source>
+                <cmr-field>
+                    <cmr-field-name>holding</cmr-field-name>
+                </cmr-field>
+            </ejb-relationship-role>
+            <ejb-relationship-role>
+                <ejb-relationship-role-name>HoldingEJB</ejb-relationship-role-name>
+                <multiplicity>One</multiplicity>
+                <cascade-delete/>
+                <relationship-role-source>
+                    <ejb-name>HoldingEJB</ejb-name>
+                </relationship-role-source>
+            </ejb-relationship-role>
+        </ejb-relation>
+    </relationships>
+    <assembly-descriptor>
+        <method-permission>
+            <description>UncheckedPermission:+:Unchecked method permission</description>
+            <unchecked/>
+            <method>
+                <ejb-name>AccountEJB</ejb-name>
+                <method-name>*</method-name>
+            </method>
+            <method>
+                <ejb-name>AccountProfileEJB</ejb-name>
+                <method-name>*</method-name>
+            </method>
+            <method>
+                <ejb-name>HoldingEJB</ejb-name>
+                <method-name>*</method-name>
+            </method>
+            <method>
+                <ejb-name>KeyGenEJB</ejb-name>
+                <method-name>*</method-name>
+            </method>
+            <method>
+                <ejb-name>KeySequenceEJB</ejb-name>
+                <method-name>*</method-name>
+            </method>
+            <method>
+                <ejb-name>OrderEJB</ejb-name>
+                <method-name>*</method-name>
+            </method>
+            <method>
+                <ejb-name>QuoteEJB</ejb-name>
+                <method-name>*</method-name>
+            </method>
+            <method>
+                <ejb-name>TradeEJB</ejb-name>
+                <method-name>*</method-name>
+            </method>
+        </method-permission>
+        <container-transaction>
+            <method>
+                <ejb-name>TradeEJB</ejb-name>
+                <method-intf>Remote</method-intf>
+                <method-name>publishQuotePriceChange</method-name>
+                <method-params>
+                    <method-param>org.apache.geronimo.samples.daytrader.QuoteDataBean</method-param>
+                    <method-param>java.math.BigDecimal</method-param>
+                    <method-param>java.math.BigDecimal</method-param>
+                    <method-param>double</method-param>
+                </method-params>
+            </method>
+            <method>
+                <ejb-name>TradeEJB</ejb-name>
+                <method-intf>Remote</method-intf>
+                <method-name>cancelOrderOnePhase</method-name>
+                <method-params>
+                    <method-param>java.lang.Integer</method-param>
+                </method-params>
+            </method>
+            <method>
+                <ejb-name>TradeEJB</ejb-name>
+                <method-intf>Remote</method-intf>
+                <method-name>completeOrderOnePhaseDirect</method-name>
+                <method-params>
+                    <method-param>java.lang.Integer</method-param>
+                </method-params>
+            </method>
+            <method>
+                <ejb-name>TradeEJB</ejb-name>
+                <method-intf>Remote</method-intf>
+                <method-name>queueOrderOnePhase</method-name>
+                <method-params>
+                    <method-param>java.lang.Integer</method-param>
+                </method-params>
+            </method>
+            <trans-attribute>RequiresNew</trans-attribute>
+        </container-transaction>
+        <container-transaction>
+            <method>
+                <ejb-name>TradeEJB</ejb-name>
+                <method-intf>Remote</method-intf>
+                <method-name>cancelOrderOnePhaseDirect</method-name>
+                <method-params>
+                    <method-param>java.lang.Integer</method-param>
+                </method-params>
+            </method>
+            <method>
+                <ejb-name>TradeEJB</ejb-name>
+                <method-intf>Remote</method-intf>
+                <method-name>completeOrderOnePhaseDirect</method-name>
+                <method-params>
+                    <method-param>java.lang.Integer</method-param>
+                </method-params>
+            </method>
+            <method>
+                <ejb-name>TradeEJB</ejb-name>
+                <method-intf>Remote</method-intf>
+                <method-name>resetTrade</method-name>
+                <method-params>
+                    <method-param>boolean</method-param>
+                </method-params>
+            </method>
+            <trans-attribute>NotSupported</trans-attribute>
+        </container-transaction>
+        <container-transaction>
+            <method>
+                <ejb-name>AccountEJB</ejb-name>
+                <method-name>*</method-name>
+            </method>
+            <method>
+                <ejb-name>AccountProfileEJB</ejb-name>
+                <method-name>*</method-name>
+            </method>
+            <method>
+                <ejb-name>HoldingEJB</ejb-name>
+                <method-name>*</method-name>
+            </method>
+            <method>
+                <ejb-name>KeyGenEJB</ejb-name>
+                <method-name>*</method-name>
+            </method>
+            <method>
+                <ejb-name>KeySequenceEJB</ejb-name>
+                <method-name>*</method-name>
+            </method>
+            <method>
+                <ejb-name>OrderEJB</ejb-name>
+                <method-name>*</method-name>
+            </method>
+            <method>
+                <ejb-name>QuoteEJB</ejb-name>
+                <method-name>*</method-name>
+            </method>
+            <method>
+                <ejb-name>TradeBrokerMDB</ejb-name>
+                <method-name>*</method-name>
+            </method>
+            <method>
+                <ejb-name>TradeEJB</ejb-name>
+                <method-name>*</method-name>
+            </method>
+            <method>
+                <ejb-name>TradeStreamerMDB</ejb-name>
+                <method-name>*</method-name>
+            </method>
+            <trans-attribute>Required</trans-attribute>
+        </container-transaction>
+        <message-destination>
+            <message-destination-name>TradeBrokerQueue</message-destination-name>
+        </message-destination>
+        <message-destination>
+            <message-destination-name>TradeStreamerTopic</message-destination-name>
+        </message-destination>
+    </assembly-descriptor>
+</ejb-jar>

Propchange: geronimo/trunk/sandbox/daytrader/modules/ejb/src/META-INF/ejb-jar.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/trunk/sandbox/daytrader/modules/streamer/src/client/META-INF/MANIFEST.MF
URL: http://svn.apache.org/viewcvs/geronimo/trunk/sandbox/daytrader/modules/streamer/src/client/META-INF/MANIFEST.MF?rev=293214&view=auto
==============================================================================
--- geronimo/trunk/sandbox/daytrader/modules/streamer/src/client/META-INF/MANIFEST.MF (added)
+++ geronimo/trunk/sandbox/daytrader/modules/streamer/src/client/META-INF/MANIFEST.MF Sun Oct  2 19:34:49 2005
@@ -0,0 +1,6 @@
+Manifest-Version: 1.0
+Class-Path:  daytrader-ejb-1.0-SNAPSHOT.jar
+Created-By: 1.4.2_08 (Sun Microsystems Inc.)
+Ant-Version: Apache Ant 1.5.4 
+Main-Class: org.apache.geronimo.samples.daytrader.client.TradeClient
+

Added: geronimo/trunk/sandbox/daytrader/modules/streamer/src/client/META-INF/application-client.xml
URL: http://svn.apache.org/viewcvs/geronimo/trunk/sandbox/daytrader/modules/streamer/src/client/META-INF/application-client.xml?rev=293214&view=auto
==============================================================================
--- geronimo/trunk/sandbox/daytrader/modules/streamer/src/client/META-INF/application-client.xml (added)
+++ geronimo/trunk/sandbox/daytrader/modules/streamer/src/client/META-INF/application-client.xml Sun Oct  2 19:34:49 2005
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<application-client id="Application-client_ID" version="1.4"
+    xmlns="http://java.sun.com/xml/ns/j2ee"
+    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/application-client_1_4.xsd">
+
+      <display-name>TradeStreamerAppClient</display-name>
+      <ejb-ref>
+         <ejb-ref-name>ejb/Trade</ejb-ref-name>
+         <ejb-ref-type>Session</ejb-ref-type>
+         <home>org.apache.geronimo.samples.daytrader.ejb.TradeHome</home>
+         <remote>org.apache.geronimo.samples.daytrader.ejb.Trade</remote>
+         <ejb-link>TradeEJB</ejb-link>
+      </ejb-ref>
+      <resource-ref>
+         <res-ref-name>jms/TopicConnectionFactory</res-ref-name>
+         <res-type>javax.jms.TopicConnectionFactory</res-type>
+         <res-auth>Application</res-auth>
+         <res-sharing-scope>Shareable</res-sharing-scope>
+      </resource-ref>
+      <message-destination-ref>
+         <message-destination-ref-name>jms/TradeStreamerTopic</message-destination-ref-name>
+         <message-destination-type>javax.jms.Topic</message-destination-type>
+         <message-destination-usage>Produces</message-destination-usage>
+         <message-destination-link>TradeStreamerTopic</message-destination-link>
+      </message-destination-ref>
+</application-client>

Propchange: geronimo/trunk/sandbox/daytrader/modules/streamer/src/client/META-INF/application-client.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/OrdersAlertFilter.java
URL: http://svn.apache.org/viewcvs/geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/OrdersAlertFilter.java?rev=293214&view=auto
==============================================================================
--- geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/OrdersAlertFilter.java (added)
+++ geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/OrdersAlertFilter.java Sun Oct  2 19:34:49 2005
@@ -0,0 +1,104 @@
+/**
+ *
+ * Copyright 2005 The Apache Software Foundation or its licensors, as applicable 
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+
+package org.apache.geronimo.samples.daytrader.web;
+
+import java.io.IOException;
+import javax.servlet.*;
+import javax.servlet.http.*;
+
+import org.apache.geronimo.samples.daytrader.soap.*;
+import org.apache.geronimo.samples.daytrader.util.*;
+
+import org.apache.geronimo.samples.daytrader.*;
+
+public class OrdersAlertFilter implements Filter {
+
+	/**
+	 * Constructor for CompletedOrdersAlertFilter
+	 */
+	public OrdersAlertFilter() {
+		super();
+	}
+
+	/**
+	 * @see Filter#init(FilterConfig)
+	 */
+	private FilterConfig filterConfig = null;
+	public void init(FilterConfig filterConfig) throws ServletException {
+	      this.filterConfig = filterConfig;
+	}
+
+	/**
+	 * @see Filter#doFilter(ServletRequest, ServletResponse, FilterChain)
+	 */
+	public void doFilter(
+		ServletRequest req,
+		ServletResponse resp,
+		FilterChain chain)
+		throws IOException, ServletException {
+		if (filterConfig == null)
+			return;
+		
+		try
+		{
+			String action = req.getParameter("action");
+			if ( action != null ) 
+			{
+				action = action.trim();
+				if ( (action.length() > 0) && (!action.equals("logout")) )
+				{
+					String userID;
+					if ( action.equals("login") )
+						userID = req.getParameter("uid");
+					else
+						userID = (String) ((HttpServletRequest) req).getSession().getAttribute("uidBean");
+					if ( (userID != null) && (userID.trim().length()>0) )
+					{	
+						TradeServices tAction=null;
+						if(TradeConfig.getAccessMode() == TradeConfig.STANDARD)
+							tAction = new TradeAction();
+						else if(TradeConfig.getAccessMode() == TradeConfig.WEBSERVICES)
+							tAction = new TradeWebSoapProxy();										
+						java.util.Collection closedOrders = tAction.getClosedOrders(userID);
+						if ( (closedOrders!=null) && (closedOrders.size() > 0) )
+							req.setAttribute("closedOrders", closedOrders);
+						if (Log.doTrace()) Log.printCollection("OrderAlertFilter: userID="+userID+" closedOrders=", closedOrders);
+					}
+				}	
+			}
+		}
+		catch (Exception e)
+		{
+			Log.error(e, "OrdersAlertFilter - Error checking for closedOrders");
+		}
+
+        ServletContext sc = filterConfig.getServletContext();
+        //String xyz = (String) sc.getAttribute("hitCounter");
+		chain.doFilter(req, resp/*wrapper*/);        
+
+	}
+
+	/**
+	 * @see Filter#destroy()
+	 */
+	public void destroy() {
+		this.filterConfig = null;	
+	}
+
+}
+

Propchange: geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/OrdersAlertFilter.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/TestServlet.java
URL: http://svn.apache.org/viewcvs/geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/TestServlet.java?rev=293214&view=auto
==============================================================================
--- geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/TestServlet.java (added)
+++ geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/TestServlet.java Sun Oct  2 19:34:49 2005
@@ -0,0 +1,107 @@
+/**
+ *
+ * Copyright 2005 The Apache Software Foundation or its licensors, as applicable 
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+
+package org.apache.geronimo.samples.daytrader.web;
+
+import javax.servlet.*;
+import javax.servlet.http.*;
+
+import org.apache.geronimo.samples.daytrader.util.*;
+
+import java.io.IOException;
+import java.math.BigDecimal;
+import org.apache.geronimo.samples.daytrader.*;
+
+public class TestServlet extends HttpServlet {
+
+
+	public void init(ServletConfig config) throws ServletException
+	{
+		super.init(config);
+	}
+	
+	
+   /**
+	* Process incoming HTTP GET requests
+	*
+	* @param request Object that encapsulates the request to the servlet
+	* @param response Object that encapsulates the response from the servlet
+	*/
+	public void doGet(HttpServletRequest request, HttpServletResponse response)
+		throws ServletException, IOException
+	{
+		performTask(request,response);
+	}
+
+   /**
+	* Process incoming HTTP POST requests
+	*
+	* @param request Object that encapsulates the request to the servlet
+	* @param response Object that encapsulates the response from the servlet
+	*/
+	public void doPost(HttpServletRequest request, HttpServletResponse response)
+		throws ServletException, IOException
+	{
+		performTask(request,response);
+	}	
+
+   /**
+	* Main service method for TradeAppServlet
+	*
+	* @param request Object that encapsulates the request to the servlet
+	* @param response Object that encapsulates the response from the servlet
+	*/    	
+	public void performTask(HttpServletRequest req, HttpServletResponse resp)
+		throws ServletException, IOException 
+	{
+		try {
+			Log.debug("Enter TestServlet doGet");
+			TradeConfig.runTimeMode = TradeConfig.DIRECT;
+			for (int i=0; i<10; i++) 
+			{
+				new TradeAction().createQuote("s:"+i, "Company " + i, new BigDecimal(i*1.1));
+			}
+			/*
+			
+			AccountDataBean accountData = new TradeAction().register("user1", "password", "fullname", "address", 
+											"email", "creditCard", new BigDecimal(123.45), false);
+
+			OrderDataBean orderData = new TradeAction().buy("user1", "s:1", 100.0);
+			orderData = new TradeAction().buy("user1", "s:2", 200.0);
+			Thread.sleep(5000);
+			accountData = new TradeAction().getAccountData("user1");
+			Collection holdingDataBeans = new TradeAction().getHoldings("user1");
+			PrintWriter out = resp.getWriter();
+			resp.setContentType("text/html");
+			out.write("<HEAD></HEAD><BODY><BR><BR>");
+			out.write(accountData.toString());
+			Log.printCollection("user1 Holdings", holdingDataBeans);
+			ServletContext sc  = getServletContext();
+			req.setAttribute("results", "Success");
+			req.setAttribute("accountData", accountData);
+			req.setAttribute("holdingDataBeans", holdingDataBeans);
+			getServletContext().getRequestDispatcher("/tradehome.jsp").include(req, resp);
+			out.write("<BR><BR>done.</BODY>");
+			*/
+		}
+		catch (Exception e)
+		{
+			Log.error("TestServletException", e);
+		}
+	}
+}
+

Propchange: geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/TestServlet.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/TradeAppServlet.java
URL: http://svn.apache.org/viewcvs/geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/TradeAppServlet.java?rev=293214&view=auto
==============================================================================
--- geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/TradeAppServlet.java (added)
+++ geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/TradeAppServlet.java Sun Oct  2 19:34:49 2005
@@ -0,0 +1,239 @@
+/**
+ *
+ * Copyright 2005 The Apache Software Foundation or its licensors, as applicable 
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+
+package org.apache.geronimo.samples.daytrader.web;
+
+import javax.servlet.*;
+import javax.servlet.http.*;
+
+import org.apache.geronimo.samples.daytrader.direct.*;
+import org.apache.geronimo.samples.daytrader.util.*;
+
+import java.io.IOException;
+import org.apache.geronimo.samples.daytrader.*;
+
+/**
+ *
+ * TradeAppServlet provides the standard web interface to Trade and can be accessed with the Go Trade! link. 
+ * Driving benchmark load using this interface requires a sophisticated web load generator that is capable of 
+ * filling HTML forms and posting dynamic data.
+ */
+
+public class TradeAppServlet extends HttpServlet {
+
+   /**
+	* Servlet initialization method.
+	*/	
+	public void init(ServletConfig config) throws ServletException
+	{
+		super.init(config);
+		java.util.Enumeration en = config.getInitParameterNames();
+		while ( en.hasMoreElements() )
+		{
+			String parm = (String) en.nextElement();
+			String value = config.getInitParameter(parm);
+			TradeConfig.setConfigParam(parm, value);
+		}
+		try
+		{
+			TradeDirect.init();		
+		}
+		catch (Exception e)
+		{
+			Log.error(e, "TradeAppServlet:init -- Error initializing TradeDirect");
+		}
+	}
+	
+	
+   /**
+	* Returns a string that contains information about TradeScenarioServlet
+	*
+	* @return The servlet information
+	*/
+	public java.lang.String getServletInfo()
+	{
+		return "TradeAppServlet provides the standard web interface to Trade";
+	}	
+
+
+   /**
+	* Process incoming HTTP GET requests
+	*
+	* @param request Object that encapsulates the request to the servlet
+	* @param response Object that encapsulates the response from the servlet
+	*/
+	public void doGet(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
+		throws ServletException, IOException
+	{
+		performTask(request,response);
+	}
+
+   /**
+	* Process incoming HTTP POST requests
+	*
+	* @param request Object that encapsulates the request to the servlet
+	* @param response Object that encapsulates the response from the servlet
+	*/
+	public void doPost(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
+		throws ServletException, IOException
+	{
+		performTask(request,response);
+	}	
+
+   /**
+	* Main service method for TradeAppServlet
+	*
+	* @param request Object that encapsulates the request to the servlet
+	* @param response Object that encapsulates the response from the servlet
+	*/    	
+	public void performTask(HttpServletRequest req, HttpServletResponse resp)
+		throws ServletException, IOException {
+
+		String action = null;
+		String userID = null;
+		// String to create full dispatch path to TradeAppServlet w/ request Parameters
+		String dispPath = null; // Dispatch Path to TradeAppServlet
+
+
+		resp.setContentType("text/html");
+		TradeServletAction tsAction = new TradeServletAction();
+
+
+		//Dyna - need status string - prepended to output
+			action = req.getParameter("action");
+
+
+			ServletContext ctx = getServletConfig().getServletContext();
+
+			if (action == null)
+			{
+				tsAction.doWelcome(ctx, req, resp, "");
+				return;
+			}
+			else if (action.equals("login"))
+			{
+				userID = req.getParameter("uid");
+				String passwd = req.getParameter("passwd");
+				String inScenario = req.getParameter("inScenario");
+				tsAction.doLogin(ctx, req, resp, userID, passwd);
+				return;
+			}
+			else if (action.equals("register"))
+			{
+				userID = req.getParameter("user id");
+				String passwd = req.getParameter("passwd");
+				String cpasswd = req.getParameter("confirm passwd");
+				String fullname = req.getParameter("Full Name");
+				String ccn = req.getParameter("Credit Card Number");
+				String money = req.getParameter("money");
+				String email = req.getParameter("email");
+				String smail = req.getParameter("snail mail");
+				tsAction.doRegister(
+					ctx, 
+					req, 
+					resp, 
+					userID, 
+					passwd, 
+					cpasswd, 
+					fullname, 
+					ccn, 
+					money, 
+					email, 
+					smail); 
+				return;
+			}
+
+			// The rest of the operations require the user to be logged in -
+			//Get the Session and validate the user.
+			HttpSession session = req.getSession();
+			userID = (String) session.getAttribute("uidBean");
+
+			if (userID == null)
+			{
+				System.out.println("TradeAppServlet service error: User Not Logged in");
+				tsAction.doWelcome(ctx, req, resp, "User Not Logged in");
+				return;
+			}
+			if ( action.equals("quotes"))
+			{
+				String symbols = req.getParameter("symbols");
+				tsAction.doQuotes(ctx, req, resp, userID, symbols);
+			}
+			else if (action.equals("buy"))
+			{
+				String symbol = req.getParameter("symbol");
+				String quantity = req.getParameter("quantity");
+				tsAction.doBuy(ctx, req, resp, userID, symbol, quantity);
+			}
+			else if (action.equals("sell"))
+			{
+				int holdingID = Integer.parseInt(req.getParameter("holdingID"));
+				tsAction.doSell(ctx, req, resp, userID, new Integer(holdingID));
+			}
+			else if (action.equals("portfolio") || action.equals("portfolioNoEdge"))
+			{
+				tsAction.doPortfolio(ctx, req, resp, userID, "Portfolio as of " + new java.util.Date());
+			}
+			else if (action.equals("logout"))
+			{
+				tsAction.doLogout(ctx, req, resp, userID);
+			}
+			else if (action.equals("home"))
+			{
+				tsAction.doHome(ctx, req, resp, userID, "Ready to Trade");
+			}
+			else if (action.equals("account"))
+			{
+				tsAction.doAccount(ctx, req, resp, userID, "");
+			}
+			else if (action.equals("update_profile"))
+			{
+				String   password = req.getParameter("password");				
+				String  cpassword = req.getParameter("cpassword");								
+				String   fullName = req.getParameter("fullname");
+				String    address = req.getParameter("address");
+				String creditcard = req.getParameter("creditcard");
+				String      email = req.getParameter("email");
+				tsAction.doAccountUpdate(
+					ctx, 
+					req, 
+					resp, 
+					userID, 
+					password   == null? "":password.trim(),
+					cpassword  == null? "":cpassword.trim(),
+					fullName   == null? "":fullName.trim(), 
+					address    == null? "":address.trim(), 
+					creditcard == null? "":creditcard.trim(), 
+					email      == null? "":email.trim()); 
+			}
+			else
+			{
+				System.out.println("TradeAppServlet: Invalid Action=" + action);
+				tsAction.doWelcome(ctx, req, resp, "TradeAppServlet: Invalid Action" + action);
+			}
+	}
+
+		
+	private void sendRedirect(HttpServletResponse resp, String page)
+		throws ServletException, IOException {
+		resp.sendRedirect(resp.encodeRedirectURL(page));
+	}
+
+	// URL Path Prefix for dispatching to TradeAppServlet
+	private final static String tasPathPrefix = "/app?action=";
+			
+}
\ No newline at end of file

Propchange: geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/TradeAppServlet.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/TradeBuildDB.java
URL: http://svn.apache.org/viewcvs/geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/TradeBuildDB.java?rev=293214&view=auto
==============================================================================
--- geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/TradeBuildDB.java (added)
+++ geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/TradeBuildDB.java Sun Oct  2 19:34:49 2005
@@ -0,0 +1,156 @@
+/**
+ *
+ * Copyright 2005 The Apache Software Foundation or its licensors, as applicable 
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+
+package org.apache.geronimo.samples.daytrader.web;
+
+import java.math.BigDecimal;
+
+import org.apache.geronimo.samples.daytrader.util.*;
+
+import org.apache.geronimo.samples.daytrader.*;
+
+/**
+ * TradeBuildDB uses operations provided by the TradeApplication to initially populate a Trade
+ * database. Specifically, a new Trade User population is created using UserIDs of the form "uid:xxx" 
+ * where xxx is a sequential number (e.g. uid:0, uid:1, etc.). New stocks are also created of the 
+ * form "s:xxx", again where xxx represents sequential numbers (e.g. s:1, s:2, etc.)
+ */
+public class TradeBuildDB {
+
+	private boolean verbose = true;
+	private TradeConfig t = new TradeConfig();
+
+	/**
+	  * Populate a Trade DB using standard out as a log
+	  */
+	public TradeBuildDB() throws Exception {
+		this(new java.io.PrintWriter(System.out));
+	}
+
+	/**
+		* Populate a Trade DB, logging to the provided output stream
+		*/
+	public TradeBuildDB(java.io.PrintWriter out) throws Exception {
+		String symbol, companyName;
+		int errorCount = 0; // Give up gracefully after 10 errors
+		TradeAction tradeAction = new TradeAction();
+
+		//  TradeStatistics.statisticsEnabled=false;  // disable statistics
+		out.println(
+			"<HEAD><BR><EM> TradeBuildDB: Building Trade Database...</EM><BR> This operation will take several minutes. Please wait...</HEAD>");
+
+		out.println("<BODY>");
+		out.println(
+			"<BR>TradeBuildDB: **** Creating " + TradeConfig.getMAX_QUOTES() + " Quotes ****</BR>");
+		//Attempt to delete all of the Trade users and Trade Quotes first
+		try
+		{
+			tradeAction.resetTrade(true);
+		}
+		catch (Exception e)
+		{
+			Log.error(e, "TradeBuildDB: Unable to delete Trade users (uid:0, uid:1, ...) and Trade Quotes (s:0, s:1, ...)");
+		}
+		for (int i = 0; i < TradeConfig.getMAX_QUOTES(); i++) {
+			symbol = "s:" + i;
+			companyName = "S" + i + " Incorporated";
+			try {
+				QuoteDataBean quoteData =
+					tradeAction.createQuote(
+						symbol,
+						companyName,
+						new java.math.BigDecimal(TradeConfig.rndPrice()));
+				if (i % 10 == 0) {
+					out.print("....." + symbol);
+					if (i % 100 == 0) {
+						out.println(" -<BR>");
+						out.flush();
+					}
+				}
+			} catch (Exception e) {
+				if (errorCount++ >= 10) {
+					String error = "Populate Trade DB aborting after 10 create quote errors. Check the EJB datasource configuration. Check the log for details <BR><BR> Exception is: <BR> " + e.toString();						
+					Log.error(e, error);
+					throw e;
+				}	
+			}
+		}
+		out.println("<BR>");
+		out.println("<BR>**** Registering " + TradeConfig.getMAX_USERS() + " Users **** ");
+		errorCount = 0; //reset for user registrations
+
+		// Registration is a formal operation in Trade 2. 
+		for (int i = 0; i < TradeConfig.getMAX_USERS(); i++) {
+			String userID = "uid:" + i;
+			String fullname = TradeConfig.rndFullName();
+			String email = TradeConfig.rndEmail(userID);
+			String address = TradeConfig.rndAddress();
+			String creditcard = TradeConfig.rndCreditCard();
+			double initialBalance = (double) (TradeConfig.rndInt(100000)) + 200000;
+			if (i == 0) {
+				initialBalance = 1000000; // uid:0 starts with a cool million.
+			}
+			try {
+				AccountDataBean accountData =
+					tradeAction.register(
+						userID,
+						"xxx",
+						fullname,
+						address,
+						email,
+						creditcard,
+						new BigDecimal(initialBalance));
+				String results;
+				if (accountData != null) {
+					if (i % 50 == 0) {
+						out.print("<BR>Account# " +accountData.getAccountID() + " userID=" + userID);
+					} // end-if
+
+					int holdings = TradeConfig.rndInt(TradeConfig.getMAX_HOLDINGS()+1); // 0-MAX_HOLDING (inclusive), avg holdings per user = (MAX-0)/2
+					double quantity = 0;
+					OrderDataBean orderData;
+					for (int j = 0; j < holdings; j++) {
+						symbol = TradeConfig.rndSymbol();
+						quantity = TradeConfig.rndQuantity();
+						orderData = tradeAction.buy(userID, symbol, quantity, TradeConfig.orderProcessingMode);
+					} // end-for
+					if (i % 50 == 0) {
+						out.println(" has " + holdings + " holdings.");
+						out.flush();
+					} // end-if
+				} else {
+					out.println("<BR>UID " + userID + " already registered.</BR>");
+					out.flush();
+				} // end-if
+
+			} catch (Exception e) {
+				if (errorCount++ >= 10) {
+					AccountProfileDataBean accountProfileData = null;
+
+					String error = "Populate Trade DB aborting after 10 user registration errors. Check the log for details. <BR><BR> Exception is: <BR>"	+ e.toString();
+					Log.error(e, error);
+					throw e;					
+				}
+			}
+		} // end-for
+		out.println("</BODY>");
+	}
+	public static void main(String args[]) throws Exception {
+		new TradeBuildDB();
+
+	}
+}
\ No newline at end of file

Propchange: geronimo/trunk/sandbox/daytrader/modules/web/src/webapp/WEB-INF/classes/org/apache/geronimo/samples/daytrader/web/TradeBuildDB.java
------------------------------------------------------------------------------
    svn:eol-style = native



Mime
View raw message