|
|
Running the sample applications require that your computer has JDK 1.2.x or higher installed. If you do not already have JDK 1.2 already on your computer download one from Sun's Java site .
Create the base directory and unpack the zip;
set the classpath and environment variables:
extract the zip file contents in some directory (the install_dir)
Edit ICsetup.bat and ICcompile.bat:
set ICECOOLBASE=install_dir (The default assumes C:\icecool
as the install_dir)
Make sure javac and java are in your %PATH% variable;
otherwise edit ICsetup.bat and
ICcompile.bat to explicitly invoke them. Type
ICsetup.bat
ICcompile.bat
Run the example application
Open 2 more command line windows: we need 3 windows;
one each to run the Registry, Server and Client applications.
In each window, cd %ICECOOLBASE% and type:
ICsetup.bat
1. In the first window, cd %ICECOOLBASE%\server and type:
runregistry
2. In the second window, cd %ICECOOLBASE%\server and type:
runserver
3. In the third window: To run the RMI client, cd %ICECOOLBASE%\client and type:
runRMIClient
To run the JNDI client, cd %ICECOOLBASE%\client and type:
runJNDIClient
The output in the client window should appear:
Connecting to registry on localhost :1099...
Invoking RMI call ...
Last Trade Price for SUNW is 101
Please follow similar steps as in ICcompile.bat for other Remote interfaces; note that the RmiClient uses JNDI and hence is not RMI dependent at all!
Browse the source files of the sample application: StockQuote.java RmiServer.java, RmiClient.java and StockQuoteImpl.java
Also, view the .log files that show the SOAP XML content used as transport messages.
| (c) 2000 IceCool.com |