Skip to main content Accessibility help
×
Hostname: page-component-78c5997874-fbnjt Total loading time: 0 Render date: 2024-11-08T08:04:55.730Z Has data issue: false hasContentIssue false

18 - Java Remote Method Invocation (RMI)

Published online by Cambridge University Press:  08 January 2010

Clark S. Lindsey
Affiliation:
Space-H Services, Maryland
Johnny S. Tolliver
Affiliation:
Oak Ridge National Laboratory, Tennessee
Thomas Lindblad
Affiliation:
Royal Institute of Technology, Stockholm
Get access

Summary

Introduction

Chapters 16 and 17 described the client/server or distributed object paradigm at a somewhat abstract level using the UML notation language. Because of the abstract nature of that discussion there was almost no Java code in either of those chapters. In fact, the only place that any code snippets appeared at all was to illustrate UML concepts in a familiar concrete Java environment.

Now we will begin to explain how to really implement the distributed object paradigm using Java Remote Method Invocation (RMI). By the end of this chapter, we will have some real code that demonstrates simple communication between two distributed Java objects, though we still won't have a running application using the architecture of Chapters 16 and 17. That complete application will be developed in Chapter 20.

Before getting to the real code, we must first describe how distributed computing can be implemented. The concepts are not particularly new, nor are they unique to Java. However, just as in other areas, the Java platform offers advantages and an easy programming style that are absent in other languages. These advantages are discussed as we explain how distributed computing works. While the full capabilities of RMI are beyond the scope of this book, we will learn the basics of RMI, and with these skills we can implement the distributed architecture described in Chapters 16 and 17.

How distributed computing works

Consider a conventional (non-distributed) computer program, be it written in Java or some other language.

Type
Chapter
Information
Publisher: Cambridge University Press
Print publication year: 2005

Access options

Get access to the full version of this content by using one of the access options below. (Log in options will check for institutional or personal access. Content may require purchase if you do not have access.)

References

Ant build tool, http://ant.apache.org
Apache open source server, www.apache.org

Save book to Kindle

To save this book to your Kindle, first ensure [email protected] is added to your Approved Personal Document E-mail List under your Personal Document Settings on the Manage Your Content and Devices page of your Amazon account. Then enter the ‘name’ part of your Kindle email address below. Find out more about saving to your Kindle.

Note you can select to save to either the @free.kindle.com or @kindle.com variations. ‘@free.kindle.com’ emails are free but can only be saved to your device when it is connected to wi-fi. ‘@kindle.com’ emails can be delivered even when you are not connected to wi-fi, but note that service fees apply.

Find out more about the Kindle Personal Document Service.

Available formats
×

Save book to Dropbox

To save content items to your account, please confirm that you agree to abide by our usage policies. If this is the first time you use this feature, you will be asked to authorise Cambridge Core to connect with your account. Find out more about saving content to Dropbox.

Available formats
×

Save book to Google Drive

To save content items to your account, please confirm that you agree to abide by our usage policies. If this is the first time you use this feature, you will be asked to authorise Cambridge Core to connect with your account. Find out more about saving content to Google Drive.

Available formats
×