View comments | RSS feed

Using EJB in JRun

This section describes features and functionality unique to the JRun EJB architecture.

JRun EJB architecture

The JRun EJB architecture features a series of interceptors, each of which manages a specific area, as the following figure shows:

This image shows the layers of the JRun EJB architecture. Local beans run outside of the server.

Stubless deployment

One of the main JRun EJB features is stubless deployment. There is no JRun EJB deploy tool. You compile the EJBs, optionally package them in a JAR file, copy the compiled EJB interfaces to the client, and define this location to the client classpath. The JRun instance proxy handles the functionality formerly managed by the stubs.

Deployment options

JRun provides a flexible EJB deployment model that makes it easy to develop and deploy beans. The following table describes the features of this deployment model:
Deployment feature
Description
Hot deploy
If hot deploy is enabled, you can deploy an EJB by copying its JAR file or directory structure into a deploy directory. By default, the JRun server root directory is set for hot deployment. To test this feature, start the samples JRun server and copy an EJB to the jrun_root/servers/samples directory.
When hot deploy is enabled, the JRun deployer detects changes to the EJB deployment descriptor and automatically redeploys the bean.
Additionally, when enabled, this feature deploys EJBs created for other application servers, including the Sun reference implementation and JRun 3.1.
Run from JAR or open directory
JRun can run your EJB from a JAR file or from an open directory structure. When the JRun deployer finds a META-INF/ejb-jar.xml file, it deploys the EJBs specified in the file. Running from an open directory structure is particularly useful during the EJB development cycle, eliminating many steps in the traditional EJB deployment and redeployment process.

The JRun EJB deployment descriptor

In addition to the standard setting in the ejb-jar.xml file, JRun lets you make additional JRun-specific settings in the JRun EJB deployment descriptor. Most J2EE application servers include a server-specific descriptor; the JRun EJB deployment descriptor is named jrun-ejb-jar.xml. The jrun-ejb-jar.xml file includes the following types of information:

For complete information on the jrun-ejb-jar.xml file, see the online descriptor documentation, available from the JRun documentation home page.

EJB clustering

When running an EJB in a JRun server that is part of a cluster, JRun automatically enables load balancing and failover, ensuring high performance and reliability.

JRun enables EJB clustering by default. To disable EJB clustering, set the cluster-home and cluster-object elements in the jrun-ejb-jar.xml file to false.

Note:   EJB clustering is not enabled for local beans.

For more information see JRun Administrator's Guide.

XDoclet

JRun provides integration with XDoclet, an open source tool that generates code and deployment descriptors for EJBs, web applications, and JSP tag libraries. Many application servers are adding support for XDoclet, and EJBs that are written using basic XDoclet tags are portable across servers.

For EJBs specifically, you can use XDoclet to do the following tasks:

To control the processing performed by XDoclet, you use a combination of jrun.xml attributes and JavaDoc-style comments in the bean implementation.

For more information on using XDoclet to develop EJBs, see Chapter 14, "EJB Programming Techniques".

The Enterprise Deployment Wizard

The JRun Enterprise Deployment Wizard streamlines the process of developing and deploying EJBs. Using its Swing-based graphical user interface, you can create any type of EJB, or edit the deployment descriptor of existing EJBs, package them into JAR files, and deploy them to JRun. In particular, the object-relational (OR) mapping capabilities of the Enterprise Deployment Wizard let you streamline the entity bean development process.

The Enterprise Deployment Wizard runs as a stand-alone tool, or as a plug-in on top of Borland JBuilder, Sun Forte, or IntelliJ IDEA.

To start the Enterprise Deployment Wizard, run jrunwizard, found in the jrun_root/bin directory.

For more details, see the Enterprise Deployment Wizard online Help.

Comments


superna said on Feb 27, 2003 at 1:36 AM :
hi i am trying to deploy a stateless session bean given in the example.. i have placed all the class file and xml files in the respective directories. whenever i try to deploy the baen through the wizard i get get the following error unrecogized deployment descriptor format.
can anyone help me
superna said on Feb 27, 2003 at 2:08 AM :
How to Deploy Stateless Session EJBs in JRun 3.1

 

RSS feed | Send me an e-mail when comments are added to this page | Comment Report

Current page: http://livedocs.adobe.com/jrun/4/Programmers_Guide/introejb5.htm