Date: 2004-01-20T05:58:49 Editor: DavanumSrinivas <[EMAIL PROTECTED]> Wiki: Apache Geronimo Wiki Page: PetStore URL: http://wiki.apache.org/geronimo/PetStore
no comment Change Log: ------------------------------------------------------------------------------ @@ -20,41 +20,40 @@ Before going on, please keep in mind that {{{"whom ever wrote petstore should be hunted down..."}}}. It's been said during one IRC session and I couldn't resist to include it. -NOTE: The directory names are all relative to '''target/geronimo-DEV''' directory. +NOTE: Unless otherwise specified the directory names are all relative to '''incubator-geronimo/target/geronimo-DEV''' directory. - 1. Define '''petstore''' directory as a place where deployables are to be found. Open '''etc/boot-service.xml''' and add '''${geronimo.home}/petstore''' after the comma, next to'''${geronimo.home}/deploy''' in '''org.apache.geronimo.kernel.deployment.scanner.DeploymentScanner''' MBean. + 1. Create '''petstore''' directory as a place where deployables are to be found. Open '''etc/boot-service.xml''' and add '''${geronimo.home}/petstore''' after the comma, next to'''${geronimo.home}/deploy''' in '''org.apache.geronimo.kernel.deployment.scanner.DeploymentScanner''' MBean. Once this is done, Geronimo will monitor the directory and attempt to deploy resources that are in the directory. - Once it's done Geronimo will monitor the directory and attempt to deploy resources that are in. + 1. Define a connection-definition of your choice in J2EECA JDBC implementation's specific way. (For OpenJCA, you can edit ''META-INF/geronimo-ra.xml'' contained in openejb-jca-DEV.jar) - 1. Define a connection-definition of your choice in J2EECA JDBC implementation's specific way. (more about it later) 1. Create '''petstore.ear''' directory within petstore directory. 1. Unjar every *-ejb.jar file of PetStore and place it in petstore/petstore.ear directory. Having the jars unjarred makes it easier to introduce changes. So, for example with asyncsender-ejb.jar: - * mkdir asyncsender-ejb + * mkdir petstore\petstore.ear\asyncsender-ejb - * cd asyncsender-ejb + * cd petstore\petstore.ear\asyncsender-ejb\asyncsender-ejb * jar -xvf <path-to>asyncsender-ejb.jar Perform the steps for the rest of EJBs, i.e. cart-ejb.jar, catalog-ejb.jar, customer-ejb.jar, petstore-ejb.jar, signon-ejb.jar, uidgen-ejb.jar - 1. Copy the rest of PetStore jars to lib directory, i.e. asyncsender-ejb-client.jar, cart-ejb-client.jar, catalog-ejb-client.jar, customer-ejb-client.jar, po-ejb-client.jar, servicelocator.jar, signon-ejb-client.jar, tracer.jar, uidgen-ejb-client.jar, xmldocuments.jar. + 1. Copy the rest of PetStore jars to lib directory (''incubator-geronimo/target/geronimo-DEV/lib'' to be precise), i.e. asyncsender-ejb-client.jar, cart-ejb-client.jar, catalog-ejb-client.jar, customer-ejb-client.jar, po-ejb-client.jar, servicelocator.jar, signon-ejb-client.jar, tracer.jar, uidgen-ejb-client.jar, xmldocuments.jar. 1. Unjar petstore.war and place it in Geronimo's petstore/petstore.ear directory. Perform the following steps: - * mkdir petstore + * mkdir petstore\petstore.ear\petstore - * cd petstore + * cd petstore\petstore.ear\petstore * jar -xvf <path-to>petstore.war - 1. Go to petstore/petstore.ear/petstore/WEB-INF/lib directory and remove the following files: cart-ejb-client.jar, catalog-ejb-client.jar, customer-ejb-client.jar, po-ejb-client.jar, servicelocator.jar, signon-ejb-client.jar, tracer.jar. They're already in lib directory and having them in that directory would be asking for ClassCastExceptions. + 1. Go to petstore/petstore.ear/petstore/WEB-INF/lib directory and remove the following files: cart-ejb-client.jar, catalog-ejb-client.jar, customer-ejb-client.jar, po-ejb-client.jar, servicelocator.jar, signon-ejb-client.jar, tracer.jar. They're already in lib directory and having them in that directory would result in ClassCastExceptions. 1. Go to petstore/petstore.ear/petstore/WEB-INF/classes/com/sun/j2ee/blueprints/petstore/controller and remove the following directories: ejb, events, exceptions. They're already in lib files (as well as they were in the just-removed jars above). Now, you understand more the quote above? - 1. Every deployable has to have Geronimo-specific deployment descriptor (g-dd) in META-INF or WEB-INF directory. Web applications have their WEB-INF/geronimo-web.xml, and ejbs META-INF/geronimo-ejb-jar.xml. These files are created based upon their relatives - WEB-INF/web.xml and META-INF/ejb-jar.xml, respectively. With a slight change standard deployment descriptor become Geronimo-specific DDs. + 1. Every deployable has to have Geronimo-specific deployment descriptor (g-dd) in META-INF or WEB-INF directory. Web applications have their WEB-INF/geronimo-web.xml, and ejbs are defined in META-INF/geronimo-ejb-jar.xml. These files are created based upon their relatives - WEB-INF/web.xml and META-INF/ejb-jar.xml, respectively. With a slight change standard deployment descriptor become Geronimo-specific DDs. * Creating WEB-INF/geronimo-web.xml