|Home > Apache Geronimo v1.1 > Documentation > Apache Geronimo v1.1 - User's Guide > Deployment plans > geronimo-application.xml|
The Geronimo deployment plan for an enterprise application is an XML document. It is defined by the geronimo-application-1.1.xsd schema, which can be found in the schema/ subdirectory of the main Geronimo installation directory. The deployment plan for an enterprise application can be included in the application EAR, in which case it should be named META-INF/geronimo-application.xml or saved as a separate file and provided to the deploy tool when the application is deployed
The deployment plan should always use the Geronimo Application namespace. Additionally, it has a required attribute to identify its configuration name, and an optional attribute to select a parent configuration. A typical enterprise application deployment plan looks like this:
15.1. Creating an Enterprise Application EAR
15.1.1. application.xml Format
15.2. The Enterprise Application Geronimo Deployment Plan
15.3. Structure of the Deployment Plan
15.3.1. Customizing the Application Class Path
15.3.2. Configuring Application Modules
15.3.3. Application-Wide Security Mapping
15.3.4. Adding Application-Scoped Services
The following sample is an Email address book which covers how to deploy the J2EE Applications on computer running Apache Geronimo v1.1.AddressBook samples has used JSP,Struts EJB and mysql as the data base.Here, it is assumed that you have the basic knowledge and experience of playing with EBJ,JSP and servlets with other application servers.
AddresBook samples use JSP primarily for presentation logic and the HTML code.Servlets form the controller layer of a typical Model-View-Controller(MVC)architecture serve as an interface between the presentation and the model layers.
The three tire architecture and layers are shown in the picture.
Following diagram shows how the code is organized in the application
AddressBook |_org.apache.geronimo.sample.addressbook.ejb | |_AddressBookEntryBean.java | |_AddressBookSessionBean.java |_org.apache.geronimo.sample.addressbook.struts | |_AddressBookEntryForm.java | |_CreateEntry.java | |_EditEntry.java | |_ListAddress.java | |_SaveEntry.java |_org.apache.geronimo.sample.addressbook.pages | |_EditAddressBook.jsp | |_footer.jsp | |_ListAddressBookPage.jsp | |_navigation.jsp | |_site-template.jsp | |_resource |_ear | |_META_INF | | |_application.xml | | |_geronimo-application.xml | |_mysql-plan.xml | |_tranql-connector-1.0-SNAPSHOT.rar | |_ejb | |_META_INF | |_openejb-jar.xml |_merge | |_README.txt | |_servlets.xml | |_servlets-mappings.xml | |_struts-controller.xml | |_strust-data-sources.xml | |_struts-forms.xml | |_struts-plugins.xml | |_taglibs.xml | |_webapp |_images |_pages |_style | |_WEB_INF | |_classes | | |_resources | | |_application.properties | |_conf | | |_struts-config.xml | | |_validation.xml | | | |_tld | |_geronimo-jetty.xml | |_tiles-defs.xml | |_validator-rules.xml |_index.jsp
JSP and Struts
The Struts action classes are in the AddressBook/src/org/apache/geronimo/sample/addressbook/struts directory. The JSPs are in the AddressBook/src/webapp/pages directory.
Apache Geronimo uses OpenEJB as the EJB container system. The example contains two EJBs:
An Application scoped connection pool is visible only to the application that deployed it.To deploy an application-scoped connection pool,you need to follow these steps.
The Application deployment descriptor(AddressBook/resources/ear/META-INF/application.xml)should define the TranQL connector module,as shown here.
|It's a must to package the connector RAR file along with the application EAR file.|
Specify the connector deployment plan file in the Geronimo application deployment Descriptor(AddressBook/resources/ear/ear/META-INF/geronimo-application.xml)as shown here.