|
| WebLogic Server 6.0 Code Examples, BEA Systems, Inc. |
Package examples.rmi.hello
This package takes the simple "HelloWorld" RMI example that is supplied
in the RMI distribution from Sun to illustrate how easy it is to convert
your RMI classes to use WebLogic RMI.
See:
Description
Interface Summary |
Hello |
This interface is the remote interface for the weblogic.rmi. |
Class Summary |
HelloClient |
This client uses the remote HelloServer methods. |
HelloImpl |
This simple example is available as part of Sun's distribution
package. |
Package examples.rmi.hello Description
This package takes the simple "HelloWorld" RMI example that is supplied
in the RMI distribution from Sun to illustrate how easy it is to convert
your RMI classes to use WebLogic RMI.
In this package the Remote interface "Hello," is implemented
by the "HelloImpl" class. The "HelloClient" class invokes the Remote
class from a simple java client.
Also included in this directory are build scripts for NT, Microsoft
SDK for Java, and UNIX. The
script compiles the files in this directory and runs the WebLogic RMI compiler
on the implementation class.
There are detailed instructions on converting Sun RMI classes to use
WebLogic RMI in the Developers Guide. The instructions here are brief
and assume that you have or will look at the Developers Guide.
The following section describes how to build and run the examples:
- Build the example
- Configure the server
- Run the example
- Set up your development shell as described in
Setting up your environment.
-
The build scripts are:
Run the appropriate build script (build.cmd, build.sh for UNIX) as shown in this
example for Windows NT:
$ build
Register the HelloImpl class as an RMI startup class
- Start the server with the examples
configuration in a new command shell.
- Bring up the Administration Console in your browser.
- Click to expand the Deployments node in the left-hand pane.
- Click to expand the Startup & Shutdown node in the left-hand pane.
- Select the hello node.
- Select the Targets tab in the right-hand pane to display the Available and Chosen targets.
- Deploy the hello startup class on the examplesServer.
Run the example
- Since startup classes are only activated when the server boots, you will
need to re-start the server with the examples
configuration.
- In you development shell, run the client application with the following command:
$ java examples.rmi.hello.HelloClient hostname port
where:
- hostname
- Host name of the WebLogic Server
- port
- Port where the WebLogic Server is listening for connections
There's more...
Read more about this WebLogic service in the Developers Guide, Using
WebLogic RMI to get more detailed information for your
application.
Copyright © 2000 BEA Systems, Inc. All Rights Reserved.