by Ann Wollrath and Jim WaldoThe Java Remote Method Invocation (RMI) system allows an object running in one Java virtual machine (VM) to invoke methods on an object running in a different Java VM.
This is a draft! Please send comments and suggestions on this trail to email@example.com with the word "RMI" in the subject. The images in this trail are too small. We are in the process of converting them.
Note: RMI provides for remote communication between programs written in Java. If one of your programs is written in another language, consider using IDL instead.
This trail provides a brief overview of the RMI system then walks through a complete client/server example that uses RMI's unique capabilities to load and execute user-defined tasks at run time. The server in the example implements a generic compute engine. The client uses the compute engine to compute the value of pi [PENDING: how do I get the pi character here?].
An Overview of RMI Applications describes the RMI system and lists advantages of it. Additionally, this lesson provides a description of the typical RMI application, composed of a server and a client, and introduces important terms.
Writing an RMI Server walks through the code for the compute engine server. Through this example, you will learn how to design and implement an RMI server.
Creating A Client Program takes a look at one possible compute engine client and uses it to illustrate the important features of an RMI client.
Compiling and Running the Example shows you how to compile and run both the compute engine server and its client.