|
What's
This About? | XML
Technologies for RPC Calls and Messaging | JAX-RPC
| JAXM
Build and Run the Sample Application
You can build and run the sample application that is highlighted in the
JAX-RPC
example and the JAXM example.
To build and run the application:
- Download and install the
Java WebServices Developer Pack v1.0_01 if it isn't already
installed.
- Download the employeeportal-fcs.zip
file into a directory. This file contains the files for the sample
application.
- Unzip the
employeeportal-fcs.zip file. This will
create an employeeportal-fcs
directory.
- Change the current directory (using the
cd command)
to the employeeportal-fcs directory.
- Set the
JWSDP_HOME environment variable to the
directory where the Java Web Services Developer Pack is installed. The
command you use to set the environment variable depends on your command
line or shell. For example, if you installed the Java Web Services
Developer Pack in directory /home/user/jwsdp-1_0-fcs
(UNIX) or /home/user/jwsdp-1_0-fcs (Windows), enter the
command:
UNIX Korn shell (ksh):
export JWSDP_HOME=/home/user/jwsdp-1_0-fcs
UNIX C shell (csh):
setenv JWSDP_HOME /home/user/jwsdp-1_0-fcs
Windows:
set JWSDP_HOME=c:\jwsdp-1_0-fcs
- Set the
ANT_HOME environment variable to JWSDP_HOME.
UNIX Korn shell (ksh):
export ANT_HOME=$JWSDP_HOME
UNIX C shell (csh):
setenv ANT_HOME $JWSDP_HOME
Windows:
set ANT_HOME%=JWSDP_HOME%
- Ensure that
ANT_HOME/bin (UNIX) or ANT_HOME\bin
(Windows) is in your path.
UNIX Korn shell (ksh):
export PATH=$ANT_HOME/bin:$PATH
UNIX C shell (csh):
setenv PATH $ANT_HOME/bin:$PATH
Windows:
set PATH=%ANT_HOME%\bin;%PATH%
- Enter the command:
ant clean
- Enter the command:
ant build-all
- Enter the command:
ant deploy
- Change the directory (cd) to
$JWSDP_HOME, and enter
the command:
UNIX
xindice-start.sh
Windows
xindice-start.bat
The command starts Java WSDP Registry Server v1.0_02. After you enter
the xindice command, examine the xindice.log
file in the $JWSDP_HOME/logs directory. If the Registry
Server is started properly, you should see the following lines in the
file:
Database: 'db' initializing Script: 'GET' added to script storage Service: 'db' started Service: 'HTTPServer' started @ http://:4080/ Service: 'APIService' started Server Running
|
- Open a new terminal window, and change the directory to
$JWSDP_HOME/bin
(UNIX) or $JWSDP_HOME/bin (Windows).
Enter the command:
UNIX
./catalina.sh run
Windows
.\catalina.sh run
The command starts the Apache Tomcat 4.1.2 container that is packaged
with the Java WSDP.
- Open a browser
- In the browser, enter the URL:
http://localhost:8080
The browser should then display the Java WSDP start page.
- Go to the first terminal window. Change the current directory to
the
employeeportal-fcs directory, and enter the following
command:
ant publish
This publishes all the service provider information into the Java WSDP
Registry Server. (You only need to perform this step once.)
- In the browser, enter the URL:
http://localhost:8080/eponfcs/index.html
The browser should then display the Employee Portal Index Page.
- Click on either the Retirement Service link or Online Book
Ordering Service link on the Employee Portal Index Page.
If you click on the Retirement Service link, the browser
should display a table of retirement funds.
- Select one or more funds, for example, Happy old days funds
and Old orchards funds.
- Specify an investment percentage for each selected fund,
for example,
Happy old days funds: 30 and Old orchards funds: 70
- Enter a monthly investment in the Investing Money field,
for example, $100
- Click the Go button. The browser should display a page with
two tables:
one that displays the funds you selected, the other that displays
quotes received from providers of the selected funds.
- Select one of the quotes, by selecting the radio button
next to it.
- Click the Confirm button. The browser should then display a
confirmation message.
If you click on the Online Book Ordering Service link, the browser
should
display a book ordering page.
- Enter one of the following search criteria:
Enter 1 in the ISBN field,
or enter Web Services in the Name of Book field,
or enter Bill Brown in the Author of Book field
The browser should then display a list of books.
- Select one book from the list.
- Click the Submit button.
[<<BACK]
[TOP]
|
|