...
This will build the jar and war files and put them in the <bmp_home>/target directory. The jar created by the Maven build contains a JBoss specific deployment descriptor, the jboss.xml file in located the META-INF directory of the JAR is shown in the following example:
Code Block | |||||||||
---|---|---|---|---|---|---|---|---|---|
| |||||||||
<?xml version="1.0"?> <jboss> <enterprise-beans> <entity> <ejb-name>CustomerEJB</ejb-name> <jndi-name>CustomerHomeRemote</jndi-name> </entity> </enterprise-beans> </jboss> |
...
The following example shows the customer-ejb.xml deployment plan used for deploying the EJB application, this deployment plan in located in the <bmp_home>/dd directory.
Code Block | ||||||||
---|---|---|---|---|---|---|---|---|
| ||||||||
<?xml version="1.0" encoding="UTF-8"?> <openejb-jar xmlns="http://www.openejb.org/xml/ns/openejb-jar" xmlns:naming="http://geronimo.apache.org/xml/ns/naming" xmlns:security="http://geronimo.apache.org/xml/ns/security" xmlns:sys="http://geronimo.apache.org/xml/ns/deployment" configId="geronimo/CustomerEJB/1.0/car" parentId="geronimo/system-database/1.0/car"> <enterprise-beans> <entity> <ejb-name>CustomerEJB</ejb-name> <jndi-name>CustomerHomeRemote</jndi-name> <local-jndi-name>CustomerRemote</local-jndi-name> <resource-ref> <ref-name>jdbc/ibm-demo</ref-name> <resource-link>SystemDatasource</resource-link> </resource-ref> </entity> </enterprise-beans> </openejb-jar> |
...
The geronimo-web.xml deployment plan should look like the following example.
Code Block | ||||||||
---|---|---|---|---|---|---|---|---|
| ||||||||
<web-app xmlns="http://geronimo.apache.org/xml/ns/web" xmlns:naming="http://geronimo.apache.org/xml/ns/naming" configId="geronimo/EntityDemoWebApp/1.0/car" parentId="geronimo/CustomerEJB/1.0/car"> <context-root>entity-ejb</context-root> <ejb-ref> <ref-name>ejb/CustomerHome</ref-name> <target-name> geronimo.server:EJBModule=geronimo/CustomerEJB/1.0/car, J2EEApplication=null,J2EEServer=geronimo, j2eeType=EntityBean,name=CustomerEJB </target-name> </ejb-ref> </web-app> |
...