1
Comparing IIOP, RMI, HTTP
by Achraf SFAXI
SUN Certified Professional
Bnak/Finance & Telecom Jobs
November 2006
 CORBA (Common Object Request Broker Architecture) is a specification for
distributed objects from the OMG (Object Management Group.) The
specification defines a language and platform-independent object bus called
an ORB (Object Request Broker), which lets objects transparently make
requests to, and receive responses from, other objects located locally or
remotely. It takes care of locating and activating servers, marshaling requests
and responses, handling concurrency, and handling exception conditions.
 IIOP (Internet Inter ORB Protocol) is an ORB transport protocol, defined as
part of the CORBA 2.0 specification, which enables network objects from
multiple CORBA-compliant ORBs to interoperate transparently over TCP/IP.
IIOP is a standard protocol whose use guarantees that CORBA-enabled objects
can communicate across CORBA runtimes from any vendor.
 Coupling the WWW and CORBA has a number of obvious benefits. The
CORBA developers and vendors gain access to the rapidly growing markets
created by the WWW, and the Web world gains access to services built using
CORBA capabilities, which are more powerful than the simple model built on
push and pull of HTML pages employed in the WWW. Integrating the two
worlds makes the best use of the available standards rather than requiring
new ones to be defined.
 CORBA and IIOP also guarantee that objects can describe their interfaces at
run-time. This offers powerful capabilities not available in other protocols,
including HTTP. Web applications will be able to take an object reference, in
the form of a URL beginning with something like "iiop://", and ask the object
to describe itself. The ability to do this in object and component models is
often called "introspection." The description takes a standard form, prescribed
by the CORBA 2.0 specification. This capability allows users much more
powerful browsing capabilities. Rather than just downloading documents,
users can interactively discover and inquire about a wider range of more
sophisticated object services.
2
 With the release of JDK version 1.1, Java has its own, built-in native ORB,
called RMI (Remote Method Invocation). RMI provides a solid platform for
truly object oriented distributed computing.
 RMI uses Object Serialization to marshal and unmarshal parameters and does
not truncate types, supporting true object-oriented polymorphism. As Java
proves itself in your environment, you can expand your Java use and get all
the benefits-no porting, low maintenance costs, and a safe, secure
environment. RMI gives you a platform to expand Java into any part your
system in an incremental fashion, adding new Java servers and clients when it
makes sense. As you add Java, its full benefits flow through all the Java in
your system. RMI makes this easy, secure, and powerful.
 In short, RMI lacks followings with respect to IIOP
1. language-neutral messaging services. In other words, RMI
objects can talk only to other RMI objects. With RMI, you cannot
invoke objects written in other languages or vice versa.
2. dynamic invocations and interface repositories.
3. wire protocol for security and transactions. RMI is both
proprietary and lightweight. It was not designed to interoperate
with other ORBs or languages. Unlike CORBA's IIOP, RMI is not
a suitable backbone for the Internet or intranets; it lacks services
IIOP provides.
 Unlike CORBA, RMI offers no concept of services. In addition, server objects
written in Java using RMI suffer from poor performance due to limitations
inherent in the Java virtual machine. (Interestingly enough, it has been shown
that Java CORBA servers perform better than Java RMI servers). RMI also
does not include any object activation policies, such as those used by CORBA
ORBs.
 Netscape, and its partners IBM, Sun and Oracle, see the power of CORBA and
want to make Internet-based services as widely available as Internet-based
content is today. Netscape has committed to integrating CORBA and IIOP
into every client and server solution it sells from now on.
 The near-perfect portability of Java applications is a great boon in a multi-
platform world; the ability to download Java applets and the close integration
of Java with Web browsers make it an ideal medium for Web- and Internet-
based development
 Though RMI is an ORB in the generic sense that it supports making method
invocations on remote objects, it's not a CORBA-compliant ORB. RMI is native
to Java. It is, in essence, an extension to the core language. RMI depends on
many of the other features of Java-object serialization, portable, down-
loadable object implementations, and Java interface definitions, among others.
The resulting mechanism is very natural for Java programmers to use. They
never have to leave the Java programming environment or learn any new
"foreign" technology. On the other hand, RMI has some limitations, principle
among which is a consequence of its greatest strength-its tight integration
3
with Java makes it impractical for use with objects or applications written in
any other language.
 Many visionaries in the distributed object community have suggested that
Java RMI can and should be implemented on top of IIOP without any loss of
Java transparency or efficiency. On the contrary, the result for Java would be
the great gain of transparent interoperability with the most powerful, widely
adopted distributed computing infrastructure existing today.
 If CORBA is so much better than RMI, then why did we need to use RMI?
RMI is another kind of CORBA/ORB that raised from Java object model. As a
ORB, RMI brings the following new functionalities:
1. allows to move code in addition to data
2. carries Java's security model to ensure that the code downloaded is safe
to run
3. allows pass by value references
4. uses Java as both an interface definition and an implementation
language
5. uses a URL-based naming scheme
 Because RMI is centered around Java, it brings the power of Java safety and
portability to distributed computing. You can move behavior, such as agents
and business logic, to the part of your network where it makes the most sense.
When you expand your use of Java in your systems, RMI allows you to take
all the advantages with you.
 RMI connects to existing and legacy systems using the standard Java native
method interface JNI. RMI can also connect to existing relational database
using the standard JDBC package. The RMI/JNI and RMI/JDBC combinations
let you use RMI to communicate today with existing servers in non-Java
languages, and to expand your use of Java to those servers when it makes
sense for you to do so. RMI lets you take full advantage of Java when you do
expand your use.
 The primary advantages of RMI are:
 Object Oriented
 Mobile Behavior (class implementations)
 Design Patterns
 Safe and Secure: RMI uses built-in Java security mechanisms
 Easy to Write/Easy to Use
 Connects to Existing/Legacy Systems
 Write Once, Run Anywhere:
 Distributed Garbage Collection: RMI uses its distributed garbage
collection feature to collect remote server objects that are no
longer referenced by any clients in the network.
 Parallel Computing: RMI is multi-threaded
 The Java Distributed Computing Solution
4
 The IIOP specification defines a set of data formatting rules, called CDR
(Common Data Representation), which is tailored to the data types supported
in the CORBA Interface Definition Language (IDL). Using the CDR data
formatting rules, the IIOP specification also defines a set of message types that
support all of the ORB semantics defined in the CORBA core specification
(http://www.omg.org/corba/corbiiop.htm). Together, the CDR formatting
rules and the message formats constitute an abstract protocol called GIOP,
which stands for General Inter-ORB Protocol. GIOP messages can be sent over
virtually any data transport protocol, such as TCP/IP, Novell SPX, SNA
protocols, etc. To ensure "out-of-the-box" interoperability between ORB
products, the IIOP specification requires that ORBs send GIOP messages over
TCP/IP connections because TCP/IP is the standard connection-oriented
transport protocol for the Internet. To put it very simply, GIOP + TCP/IP =
IIOP.
 As a conclusion retain that :
 CORBA is a specification for distributed objects from the OMG
 ORB is a language and platform-independent object Bus
 IIOP is an ORB transport Protocol
 RMI is a specification of distributed objects that has its own
native ORB. It is totally based on Java
If you appreciate this document make a donation to a
worldwide children association or organization. I suggest the SOS
association. This document has been downloaded from the
http://achraf.sfaxi.perso.sfr.fr space ; you can use and broadcast it for
non lucrative purposes. Further information are available upon
request.
Si vous appréciez ce document faites un don pour le compte
d’une association ou une organisation qui s’occupe des enfants. Je
recommande l’association SOS. Ce document est disponible sur
http://achraf.http://achraf.sfaxi.perso.sfr.frsfaxi.perso.sfr.fr; son utilisation
ainsi que sa propagation pour des fins non lucratives sont gratuites.

Distributed computing - november 2006

  • 1.
    1 Comparing IIOP, RMI,HTTP by Achraf SFAXI SUN Certified Professional Bnak/Finance & Telecom Jobs November 2006  CORBA (Common Object Request Broker Architecture) is a specification for distributed objects from the OMG (Object Management Group.) The specification defines a language and platform-independent object bus called an ORB (Object Request Broker), which lets objects transparently make requests to, and receive responses from, other objects located locally or remotely. It takes care of locating and activating servers, marshaling requests and responses, handling concurrency, and handling exception conditions.  IIOP (Internet Inter ORB Protocol) is an ORB transport protocol, defined as part of the CORBA 2.0 specification, which enables network objects from multiple CORBA-compliant ORBs to interoperate transparently over TCP/IP. IIOP is a standard protocol whose use guarantees that CORBA-enabled objects can communicate across CORBA runtimes from any vendor.  Coupling the WWW and CORBA has a number of obvious benefits. The CORBA developers and vendors gain access to the rapidly growing markets created by the WWW, and the Web world gains access to services built using CORBA capabilities, which are more powerful than the simple model built on push and pull of HTML pages employed in the WWW. Integrating the two worlds makes the best use of the available standards rather than requiring new ones to be defined.  CORBA and IIOP also guarantee that objects can describe their interfaces at run-time. This offers powerful capabilities not available in other protocols, including HTTP. Web applications will be able to take an object reference, in the form of a URL beginning with something like "iiop://", and ask the object to describe itself. The ability to do this in object and component models is often called "introspection." The description takes a standard form, prescribed by the CORBA 2.0 specification. This capability allows users much more powerful browsing capabilities. Rather than just downloading documents, users can interactively discover and inquire about a wider range of more sophisticated object services.
  • 2.
    2  With therelease of JDK version 1.1, Java has its own, built-in native ORB, called RMI (Remote Method Invocation). RMI provides a solid platform for truly object oriented distributed computing.  RMI uses Object Serialization to marshal and unmarshal parameters and does not truncate types, supporting true object-oriented polymorphism. As Java proves itself in your environment, you can expand your Java use and get all the benefits-no porting, low maintenance costs, and a safe, secure environment. RMI gives you a platform to expand Java into any part your system in an incremental fashion, adding new Java servers and clients when it makes sense. As you add Java, its full benefits flow through all the Java in your system. RMI makes this easy, secure, and powerful.  In short, RMI lacks followings with respect to IIOP 1. language-neutral messaging services. In other words, RMI objects can talk only to other RMI objects. With RMI, you cannot invoke objects written in other languages or vice versa. 2. dynamic invocations and interface repositories. 3. wire protocol for security and transactions. RMI is both proprietary and lightweight. It was not designed to interoperate with other ORBs or languages. Unlike CORBA's IIOP, RMI is not a suitable backbone for the Internet or intranets; it lacks services IIOP provides.  Unlike CORBA, RMI offers no concept of services. In addition, server objects written in Java using RMI suffer from poor performance due to limitations inherent in the Java virtual machine. (Interestingly enough, it has been shown that Java CORBA servers perform better than Java RMI servers). RMI also does not include any object activation policies, such as those used by CORBA ORBs.  Netscape, and its partners IBM, Sun and Oracle, see the power of CORBA and want to make Internet-based services as widely available as Internet-based content is today. Netscape has committed to integrating CORBA and IIOP into every client and server solution it sells from now on.  The near-perfect portability of Java applications is a great boon in a multi- platform world; the ability to download Java applets and the close integration of Java with Web browsers make it an ideal medium for Web- and Internet- based development  Though RMI is an ORB in the generic sense that it supports making method invocations on remote objects, it's not a CORBA-compliant ORB. RMI is native to Java. It is, in essence, an extension to the core language. RMI depends on many of the other features of Java-object serialization, portable, down- loadable object implementations, and Java interface definitions, among others. The resulting mechanism is very natural for Java programmers to use. They never have to leave the Java programming environment or learn any new "foreign" technology. On the other hand, RMI has some limitations, principle among which is a consequence of its greatest strength-its tight integration
  • 3.
    3 with Java makesit impractical for use with objects or applications written in any other language.  Many visionaries in the distributed object community have suggested that Java RMI can and should be implemented on top of IIOP without any loss of Java transparency or efficiency. On the contrary, the result for Java would be the great gain of transparent interoperability with the most powerful, widely adopted distributed computing infrastructure existing today.  If CORBA is so much better than RMI, then why did we need to use RMI? RMI is another kind of CORBA/ORB that raised from Java object model. As a ORB, RMI brings the following new functionalities: 1. allows to move code in addition to data 2. carries Java's security model to ensure that the code downloaded is safe to run 3. allows pass by value references 4. uses Java as both an interface definition and an implementation language 5. uses a URL-based naming scheme  Because RMI is centered around Java, it brings the power of Java safety and portability to distributed computing. You can move behavior, such as agents and business logic, to the part of your network where it makes the most sense. When you expand your use of Java in your systems, RMI allows you to take all the advantages with you.  RMI connects to existing and legacy systems using the standard Java native method interface JNI. RMI can also connect to existing relational database using the standard JDBC package. The RMI/JNI and RMI/JDBC combinations let you use RMI to communicate today with existing servers in non-Java languages, and to expand your use of Java to those servers when it makes sense for you to do so. RMI lets you take full advantage of Java when you do expand your use.  The primary advantages of RMI are:  Object Oriented  Mobile Behavior (class implementations)  Design Patterns  Safe and Secure: RMI uses built-in Java security mechanisms  Easy to Write/Easy to Use  Connects to Existing/Legacy Systems  Write Once, Run Anywhere:  Distributed Garbage Collection: RMI uses its distributed garbage collection feature to collect remote server objects that are no longer referenced by any clients in the network.  Parallel Computing: RMI is multi-threaded  The Java Distributed Computing Solution
  • 4.
    4  The IIOPspecification defines a set of data formatting rules, called CDR (Common Data Representation), which is tailored to the data types supported in the CORBA Interface Definition Language (IDL). Using the CDR data formatting rules, the IIOP specification also defines a set of message types that support all of the ORB semantics defined in the CORBA core specification (http://www.omg.org/corba/corbiiop.htm). Together, the CDR formatting rules and the message formats constitute an abstract protocol called GIOP, which stands for General Inter-ORB Protocol. GIOP messages can be sent over virtually any data transport protocol, such as TCP/IP, Novell SPX, SNA protocols, etc. To ensure "out-of-the-box" interoperability between ORB products, the IIOP specification requires that ORBs send GIOP messages over TCP/IP connections because TCP/IP is the standard connection-oriented transport protocol for the Internet. To put it very simply, GIOP + TCP/IP = IIOP.  As a conclusion retain that :  CORBA is a specification for distributed objects from the OMG  ORB is a language and platform-independent object Bus  IIOP is an ORB transport Protocol  RMI is a specification of distributed objects that has its own native ORB. It is totally based on Java If you appreciate this document make a donation to a worldwide children association or organization. I suggest the SOS association. This document has been downloaded from the http://achraf.sfaxi.perso.sfr.fr space ; you can use and broadcast it for non lucrative purposes. Further information are available upon request. Si vous appréciez ce document faites un don pour le compte d’une association ou une organisation qui s’occupe des enfants. Je recommande l’association SOS. Ce document est disponible sur http://achraf.http://achraf.sfaxi.perso.sfr.frsfaxi.perso.sfr.fr; son utilisation ainsi que sa propagation pour des fins non lucratives sont gratuites.