Document Information

Preface

1.  Introduction

2.  The Java Platform, Enterprise Edition

3.  Creating Your First Java EE Application

4.  Building, Packaging, and Deploying and Running the Example Application

Deploying the Example Application

Deploying the Enterprise Bean and Web Client

Deploying firstcup.ear Using Ant

Running the Web Client

Running the firstcup Application

Undeploying the Application

Undeploying with Ant

Undeploying with asadmin

5.  Next Steps

 

Building and Packaging the Example Application

This section describes how to build the example application.

Building and Packaging the Example Application Using Ant

Building and Packaging firstcup-dukes-age Using Ant

This task builds firstcup-dukes-age and creates a WAR file, firstcup-dukes-age.war, in the dist directory.

  1. Verify that you have added the Ant build tool that comes with the Application Server to your path. The location is the lib/ant/bin directory of your Application Server installation.
  2. In a terminal, go to <INSTALL>/firstcup/example/firstcup-dukes-age.
  3. Enter the following command:
    ant

    You should see Build Successful when the command finishes.

Deploying firstcup-dukes-age.war Using Ant

This task gives instructions on deploying firstcup-dukes-age.war using Ant.

  1. Start the Application Server if you haven't already. Refer to your Application Server documentation if you are not sure how to start the server.
  2. In a terminal go to <INSTALL>/firstcup/example/firstcup-dukes-age.
  3. Enter the following command:
    ant deploy

    You should see Build Successful when the command finishes.

Building and Packaging DukesBirthdayBean and firstcup Using Ant
  1. In a terminal, go to <INSTALL>/firstcup/example/firstcup.
  2. Enter the following command:
    ant

    You should see Build Successful when the command finishes.