Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

On the Archive: field browse to the CurrencyConverterEJB.jar file you just extracted and click "Install", this will install and start the JAR. You can verify the status of this JAR by clicking on EJB JARs link from the menu on the left. It should display something like this:

No Format
borderColor#FFFFFF
bgColor#FFFFFF
borderStylesolid
nopaneltrue
 Component Name                                          State
 default/CurrencyConverterEJB/1199743733609/jar          running

WebAppEjbAccessAnnotations.war includes a Servlet and a JSP. The following excerpt shows the annotation part the wizard has identified and will likely be prompting for additional information while deploying the application.

Code Block
java
java
borderStylesolid
titleExcerpt from ConverterHandler.java

...
public class ConverterHandler extends javax.servlet.http.HttpServlet implements
		javax.servlet.Servlet {
	@EJB(name = "ejb/Converter")
	private Converter converter;
...

With the prerequisite JAR just installed click on Plan Creator on the left menu to proceed with the WAR installation. Browse to the WebAppEjbAccessAnnotations.war you just extracted and click on Configure. In the resulting screen you will be configuring the web application identity. You may want to change the default proposed values however, for this example, we will be accepting the defaults. Click Next.

In the following screen, the wizard have identified some WAR references that need to be resolved. The references listed on this screen are specific to this application. The EJBRef column is showing the resource name defined in ConverterHandler.java; see *@EJB(name = "ejb/Converter") from the excerpt above.

From the EJBs Deployed pull-down menu select the JAR you deployed earlier ConverterBean (default/CurrencyConverterEJB/1199743733609/jar) and click Next.

The following screen list all available modules and allows you specify additional modules this WAR has dependencies on. This screen also provides a default selection, in this case the EJB JAR you deployed previously will be already selected. Accept the default and click Next. For most scenarios the default values should be sufficient.

The final configuration page displays the generated deployment plan and allows you to make any additional editing. The following example shows the generated deployment plan.

Code Block
xml
xml
borderStylesolid
titleGenerated deployment plan
<?xml version="1.0" encoding="UTF-8"?>
<web-app xmlns="http://geronimo.apache.org/xml/ns/j2ee/web-2.0.1">
    <dep:environment xmlns:dep="http://geronimo.apache.org/xml/ns/deployment-1.2">
        <dep:moduleId>
            <dep:groupId>default</dep:groupId>
            <dep:artifactId>WebAppEjbAccessAnnotations</dep:artifactId>
            <dep:version>1.0</dep:version>
            <dep:type>war</dep:type>
        </dep:moduleId>
        <dep:dependencies>
            <dep:dependency>
                <dep:groupId>default</dep:groupId>
                <dep:artifactId>CurrencyConverterEJB</dep:artifactId>
                <dep:version>1199740963562<version>1199743733609</dep:version>
                <dep:type>jar</dep:type>
            </dep:dependency>
        </dep:dependencies>
    </dep:environment>
    <context-root>WebAppEjbAccessAnnotations</context-root>
    <nam:ejb-ref xmlns:nam="http://geronimo.apache.org/xml/ns/naming-1.2">
        <nam:ref-name>ejb/Converter</nam:ref-name>
        <nam:pattern>
            <nam:groupId>default</nam:groupId>
            <nam:artifactId>CurrencyConverterEJB</nam:artifactId>
            <nam:version>1199740963562<version>1199743733609</nam:version>
            <nam:name>ConverterBean</nam:name>
        </nam:pattern>
    </nam:ejb-ref>
</web-app>

The last step is to actually deploy and start the application, click on Deploy WAR.

You should receive two confirmation messages stating the application was successfully deployed and successfully started. The Launch Web App link takes your browser directly to the application you just deployed based on the context root you defined earlier. Finish takes you to the Plan Creator portlet again to start deploying a new application.

JMS access
Anchor
jms
jms

A simple web app that accesses a JMS Connection Factory and a JMS destination. 'Producer' servlet sends 5 messages to a JMS queue and 'Consumer' servlet synchronously receives messages from the same queue.

...