background image

Packaging the Application

<< Starting the Application Server | Running the Application Client >>
<< Starting the Application Server | Running the Application Client >>
P
ACKAGING THE
A
PPLICATION
209
To create the connector resource, perform the following steps:
1. Under the Connectors node, click Connector Resources.
2. Click New. The Create Connector Resource page appears.
3. In the JNDI Name field, type
eis/JAXR
.
4. Choose
jaxr-pool
from the Pool Name drop-down list.
5. Click OK.
If you are in a hurry, you can create these objects by executing the following
command (from the directory
<INSTALL>/javaeetutorial5/examples/jaxr/
clientsession
):
asant create-resource
Packaging the Application
The
build.xml
file in the
clientsession
directory defines Ant targets that
package the
clientsession
application. To package the application, use the fol-
lowing command:
asant pack-ear
The
pack-ear
target depends on the
pack-client
and
pack-ejb
targets, which
in turn depend on the
build
target.
The
pack-client
target creates a JAR file that contains the client class file, a
manifest file, and the
PubQueryBeanExample.properties
file.
The
pack-ejb
target packages the session bean. It creates a JAR file that con-
tains the bean class files, a manifest file, and the
PubQueryBeanExample.prop-
erties
file.
The
pack-ear
target packages the two JAR files along with an
applica-
tion.xml
file. It creates a file named
clientsession.ear
in the
clientses-
sion
directory.