You are on page 1of 25

By Jihed Othmani Jing Wang Karim Jouini Mathieu Martin

1

Outline
 The need  RPC (Remote Procedure Call)
   

Quick introduction Samples Advantages & disadvantages Future?

 RMI (Remote Method Invocation)
   

Quick introduction Samples Advantages & disadvantages Future?

 WebServices
 Quick introduction  Samples  Advantages & disadvantages

 Recap & Conclusion
2

 So : we need a standardization of protocols to ease communication at the application layer.  That’s what we call middlewares.  Provide a service without sharing code. tempting us to take advantage of their computational capabilities. 3 . reuse code.The Need  More and more devices are connected.  There are a lot of opportunities to leverage services offered by others and to make your application publicly available.  We would like to communicate. share services.

4 .

1981.  Paradigm:  The client process has to “know” the serving process and instantiates the communication.  RPC was first described in 1976 by the RFC707.RPC – Quick Introduction  First system to address the need to communicate across process’ and machines boundaries.  Xerox used RPC in the popular software “courier”. 5 .  The client process calls a distant procedure and waits for the response (or fail).

RPC – Samples  A “simple” server (part 1) 6 .

 A “simple” server (part 2) 7 .

 A “simple” client using our previous server 8 .

RPC – Advantages  Advantages :  Very simple logic and very low level.  Can be implemented by any language (including C !).  RPC exists since 1976. 9 . so its maturity and solidity are undoubted. gives to the programmer a lot of freedom to implement different mechanisms on top of it.

blaster.RPC – Disadvantages  Using RPC can become very complex  The complexity is exposed as the number of procedures  Interaction with such a module requires using all these interfaces in the right way and sequence.  A lot of code is needed for even simple applications. Security? Sasser. etc … Are RPC-vulnerability exploits  There are multiple different and incompatible RPC protocols.  RPC gives no answer to fundamental questions:      How to find peers ? How to distribute the workload over multiple servers? How failure and recovery should be handled? How to send/receive complex data structures. 10 .

that would be able to provide us with :  OOP  Load balancing  Failure detection/correction  Etc … 11 .RPC – Future ?  RPC is way too complex to be used as middleware in modern software.  RPC can be used as low level layer for more powerful middleware layers.

12 .

 Java Remote Method Protocol (JRMP)  In order to support servers running in a non-JVM context.RMI – Quick Introduction  The Java Remote Method Invocation API.  Uses HTTP or IIOP as communication layer. 13 . is a Java application programming interface for performing the object equivalent of Remote Procedure Calls. or Java RMI.  There are two common implementations of the API. a CORBA version was later developed.

RMI – Samples  Here is a Server publishing a “Hello” Object 14 .

RMI – Samples  Here is client invoking the previous “Hello” Object and calling “HelloFromServer()” On it ! 15 .

 Latest versions are CORBA-compatible (using IIOP).  First attempt to address security.  Asynchronous possibilities with ARMI (Async’-RMI).  Disadvantages  Java only… 16 .  NAT-Firewall traversal capabilities.  Easier to use and setup than CORBA.  RDMI enables dynamic invocation. so portable and Oriented Object.RMI – Advantages & disadvantages  Advantages  Java.

RMI – Future ?  RMI still needs to find answers to:  How to implement real server-level security ?  How to perform load balancing ?  How to use RMI in other languages ? 17 .

18 .

19 .Web Services – Quick Introduction  A software system designed to support interoperable machine-to-machine interaction over a network.  Web services range from such major services as storage management down to much more limited services such as the furnishing of a stock quote.  It refers to clients and servers that communicate over the HTTP protocol used on the Web.

  Mashups (ex: Jogli. Evolutionary thanks to XML.  Opportunities to take advantage of services offered by others and to make your applications available to others as a Web service. For example:     The HTTP standard allows more systems to communicate with one another. Business Oriented. WSDL standardizes the description of Web services.Web Services – Advantages       Universal Support. SOAP (built on XML) standardizes the messaging capability on different systems. so providers and requesters speak the same language.com) 20 . UDDI standardizes the publishing and finding of Web services. Protocol not Platform. The standardized nature of the pieces that implement a Web service solves many problems related to intersystem communication. Low Product Costs.

 But:    To buy a faster CPU is cheaper than employing a programmer and systems administrator capable of handling RMI. You can use cloud systems to easily scale. 21 .  No load balancing at the protocol level.Web Services – Disadvantages  No security standards: Web services are exposed to the public using http-based protocols.  Processing time and data traffic costs are significantly higher  Very verbose : Multiplication of the conveyed information mass.  Adopting open security standards like SSL or XML-encryption may be a solution. Performance differences less marked for more realistic applications than for toys like “calculator”.

collection of information about existing Web services.access the Google search engine.  Getting the last stock quote.Web Services – Samples  Google's Web Service . 22 .  Amazon's Web Service .  XMethods .access Amazon's product information .

23 .

1981 Library and OSdependant OS-Dependent Huge RMI ~ 1990 Java HTTP or IIOP Reasonable Web Services ~ 2000 Independent  HTTP(s) Low Security Overhead Dynamic invocation Versioning Service lookup None None None Huge problem Impossible Client-level OOP + HTTP Yes.Recap RPC Birth Platform Transport Dev Cost 1976 . using RDMI Possible using RDMI Java Naming and Directory Transport Level XML + HTTP Natural Natural UDDI 24 .

25 .