RMI (Java RMI) - PowerPoint PPT Presentation

About This Presentation
Title:

RMI (Java RMI)

Description:

Clients must re-bind to get new clone. Symbolic values representing objects in the real world ... Not true in computer world, so how to enforce the semantics? ... – PowerPoint PPT presentation

Number of Views:53
Avg rating:3.0/5.0
Slides: 6
Provided by: DePaulUn
Category:
Tags: rmi | cw | java | new | the

less

Transcript and Presenter's Notes

Title: RMI (Java RMI)


1
RMI (Java RMI)
  • P 460 in text
  • UUIDs / system wide references
  • Transparent all objects either by ref. or by
    value. Not efficient, especially int, bool, etc
  • (Probable error in the book by ref pp 2)
  • Pass local and remote differently. Not
    transparent.
  • Proxy is a local object (and also a ref!)

2
  • Fig 10-8
  • Java not always transparent
  • Serializable means can be marshaled
  • Passing messages under the hood
  • Local are passed by Value, remote by ref.
  • Pass by value means COPYing object
  • Problem cardinal sin of CS is to copy data
  • Clone local copy object and state - indentcl
  • Clone remote only on server. Otherwise have to
    clone all client references to it as well.
    Clients must re-bind to get new clone.

3
  • Symbolic values representing objects in the real
    world are basis of programming
  • Real world objects live in one place. When they
    move they are no longer where they used to be.
  • Not true in computer world, so how to enforce the
    semantics?

4
  • Protocol part of both classes (remote and local)
    that make a remote object.
  • Network address / endpoint (port) and local name,
    yielding effective UUID.
  • Object on server. Contains state, methods
  • Server side stub / skeleton for code interface
  • Client side stub, or proxy, for code interface
  • Each invocation sets up connection, then
    connection is torn down.
  • Proxies themselves can be marshaled and sent to
    other locations. Portable ref to obj.

5
  • Proxy is a local object.
  • So, proxy can be passed as a ref in RMI
  • In theory whole proxy is sent (copied) as
    argument, but in practice implementation classes
    are often already available, and thus passed by
    reference.
  • So, references to remote objects are small.
  • Can also tweak to make local copies of object
    that does not change often.
  • Only possible because of virtual machine. DCE
    has to pre-compile all code.
Write a Comment
User Comments (0)
About PowerShow.com