Red Hat Application Server: JOnAS User Guide | ||
---|---|---|
Prev | Chapter 1. Java Open Application Server (JOnAS): a J2EE Platform | Next |
The JOnAS development and deployment environment comprises the JOnAS configuration and deployment facilities and the JOnAS development environment.
Once JOnAS has been installed in a directory referenced by the JONAS_ROOT environment variable, it is possible to configure servers and to deploy applications into several execution environments. This is achieved using the JONAS_BASE environment variable. JONAS_ROOT and JONAS_BASE can be compared to the CATALINA_HOME and CATALINA_BASE variables of Tomcat. While JONAS_ROOT is dedicated to JOnAS installation, JONAS_BASE is used to specify a particular JOnAS instance configuration. JONAS_BASE designates a directory containing a specific JOnAS configuration, and it identifies subdirectories containing the EJB-JAR, WAR, EAR, and RAR files that can be loaded in this application environment. There is an ANT target in the JOnAS build.xml file for creating a new JONAS_BASE directory structure. Thus, from one JOnAS installation, it is possible to switch from one application environment to another by just changing the value of the JONAS_BASE variable.
There are two ways to configure a JOnAS application server and load applications: either by using the administration console or by editing the configuration files. There are also "autoload" directories for each type of application and resource (EJB-JAR, WAR, EAR, RAR) that allow the JOnAS server to automatically load the applications located in these directories when starting.
JOnAS provides several facilities for deployment:
For writing the deployment descriptors, plugins for Integrated Development Environments (IDE) provide some generation and editing features (Eclipse and JBuilder plugins are available). The NewBean JOnAS built-in tool generates template deployment descriptors. The Xdoclet tool also generates deployment descriptors for JOnAS. The Apollon ObjectWeb project generates Graphical User Interfaces for editing any XML file; it has been used to generate a deployment descriptor editor GUI (see http://debian-sf.objectweb.org/projects/apollon). A deployment tool developed by the ObjectWeb JOnAS community, earsetup (http://sourceforge.net/projects/earsetup), will also be available for working with the JSR88-compliant (J2EE 1.4) deployment APIs provided by the ObjectWeb Ishmael project (see http://sourceforge.net/projects/earsetup/ and http://debian-sf.objectweb.org/projects/ishmael/ respectively.
Some basic tools for the deployment itself are the JOnAS GenIC command line tool and the corresponding ANT EJB-JAR task. The IDE plugins integrate the use of these tools for deployment operations. The main feature of the Ishmael project will be the deployment of applications on the JOnAS platform.
There are many plugins and tools that facilitate the development of J2EE applications to be deployed on JOnAS. IDE plugins for JBuilder Kelly (http://forge.objectweb.org/projects/kelly/), JOPE (http://forge.objectweb.org/projects/jope/), and Lomboz (http://lomboz.objectweb.org) provide the means to develop, deploy, and debug J2EE components on JOnAS. The Xdoclet code generation engine (http://xdoclet.sourceforge.net/) can generate EJB interfaces and deployment descriptors (standard and JOnAS specific ones), taking as input the EJB implementation class containing specific JavaDoc tags. The JOnAS NewBean tool generates templates of interfaces, implementation class, and deployment descriptors for any kind of EJB. Many development tools may work with JOnAS; refer to the JOnAS tools page at http://www.objectweb.org/jonas/tools.html for more details.
In addition, JOnAS is delivered with complete J2EE examples, providing a build.xml ANT file with all the necessary targets for compiling, deploying, and installing J2EE applications.