RPC, RMI and CORBA
RPC, RMI and CORBA RPC, RMI and CORBA
Design Exercise – a remote procedurecall protocol• Service – Remote Cryptographic Engine (RCE)• Module has the following APIpublic String encrypt( int[] key, String plaintext)public String derypt( int[] key, String cyphertext)public String messageDigest( String plaintext)where: key is an array of 4 32-bit integers
Programming with RMI*• create a remote object• define a remote interface (CORBA IDL or Java)• create an implementation of the remote interface• make available to users• by registering with a name service• by passing as an argument or a return value• use a remote object:• obtain a remote reference• by “bootstrapping” (from a name service)• as an argument or return value• reference is to remote interface type not implementation class• operate on the reference• standard method invocation syntax• multiple possible semantics• be prepared to handle errors from partial failure* In these lectures, RMI means remote method invocationgenerally, unless Java RMI is specifically indicated
- Page 1: Object-based DistributedSystemsEEE4
- Page 6: Programming Model• integrated int
- Page 10 and 11: Define a Remote Interface• the in
- Page 12 and 13: Make Available to Users• “boots
- Page 14 and 15: Client Side: Obtain a Remote Refere
- Page 16 and 17: Java RMI Development ProcessDevelop
- Page 18 and 19: Structure of an RMI Application•
- Page 20 and 21: Remote Object Implementation
- Page 22 and 23: RMI Mechanism• Work through colla
- Page 24 and 25: package server;import java.rmi.regi
- Page 26 and 27: This file was generated by the RMI
- Page 28 and 29: Review• RMI Semantics
- Page 30 and 31: Specification of the OperationsIn p
- Page 32 and 33: Possible Exchange Protocols• Look
- Page 34 and 35: Duplicate Requests• Since client
- Page 36 and 37: History• When a server cannot saf
- Page 38: Examples:• Specify:• the semant
Programming with <strong>RMI</strong>*• create a remote object• define a remote interface (<strong>CORBA</strong> IDL or Java)• create an implementation of the remote interface• make available to users• by registering with a name service• by passing as an argument or a return value• use a remote object:• obtain a remote reference• by “bootstrapping” (from a name service)• as an argument or return value• reference is to remote interface type not implementation class• operate on the reference• st<strong>and</strong>ard method invocation syntax• multiple possible semantics• be prepared to h<strong>and</strong>le errors from partial failure* In these lectures, <strong>RMI</strong> means remote method invocationgenerally, unless Java <strong>RMI</strong> is specifically indicated