Install the J2EE SDK

foreheadsobstinacySoftware and s/w Development

Aug 15, 2012 (5 years ago)

227 views

1. Install the J2EE SDK 1.4. This will install J2EE 1.4 and J2SDK SE 5.0 as well.

http://java.sun.com/j2ee/1.4/download.html#sdk



Specify an admin user name and password. DO NOT FORGET WH
AT YOU
USE!!



Install in the C:
\
Sun
\
AppServer directory



To access once the install is complete, click
Start > Programs >
SunMicrosystems > Application Server PE



From here, you can start and stop the server, and access Deploytool


2. If you do not have NetBe
ans installed, d
ownload J2SE and NetBeans IDE Cobundle
NB 5.0 / J2SE 1.4.2_13 for Windows

http://java.sun.com/j2se/1.4.2/download
-
netbeans.html



Install on the C: drive of your
computer.



3.

Register the server with the NetBeans IDE

a.

Within NetBeans:

Choose Tools > Server Manager from the main window.

Click Add Server. Select the server type and give a name to the instance. Then
click Next.

Specify the server information, the l
ocation of the local instance of the
application server, and the domain to which you want to deploy
.

4.

To package the sample Hello application from NetBeans

5.

To package the Hello application using asant

a.

Add C:
\
Sun
\
AppServer
\
bin to your PATH environment variab
le

i.

Click Start > Run, Type CMD, Press Enter

ii.

From the command prompt, type “PATH” and press enter. This will
display your PATH env variable.

iii.

To add a new entry, type:

Set path=%PATH%;C:
\
Sun
\
AppServer
\
bin

iv.

Type PATH again to verify the new entry was appende
d to the end

v.

Go to C:
\
Sun
\
AppServer
\
samples
\
quickstart
\

vi.

Type
asant war

vii.

This will create the WAR file for the application in
C:
\
Sun
\
AppServer
\
samples
\
quickstart
\
build
\
assemble
\
war


6.

Deploy a web application from the admin console

a.

Start the admin console thro
ugh the start menu or going to
http://localhost:4848

b.

Enter your admin username and password

c.

In the left panel, click the Application node to expand.

d.

Click Web Applications

e.

If Hello is already deployed, undeploy it by
checking the box and clicking
undeploy

f.

To deploy your newly assembled Hello application (WAR file), on the Web
Applications page click
Deploy

g.

Select “Specify a package file to upload to the Application Server” and click
Browse

h.

Navigate to the directory whe
re you installed the Server (probably
C:
\
Sun
\
AppServer)

i.

In the AppServer directory, navigate to
\
samples
\
quickstart
\
build
\
assemble
\
war
\

and select Hello.war

j.

Click Next

k.

On the deploy module web page, click Ok

l.

The application appears in the Web Application l
ist.

m.

To verify it deployed correctly, click Launch. The application should appear.


7.

Install the Tutorial Bundle for sample code:
http://java.sun.com/j2ee/1.4/download.html#tutorial


8.

Complete 879
-
896 of the J2EE Tutorial on Enterprise Beans. See Links page for
a link to the PDF document or your handout.