Corba Unit 4
Corba Unit 4
Corba Unit 4
RMI CORBA
RMI is a Java-specific technology CORBA has implementation for
many languages
It uses Java interface for It uses Interface Definition Language
implementation. (IDL) to separate interface from
implementation
RMI objects are garbage collected CORBA objects are not garbage
automatically. collected because it is language
independent and some languages like
C++ does not support garbage
collection.
RMI programs can download new CORBA does not this code sharing
classes from remote JVM’s. mechanism
RMI uses the Java Remote CORBA use Internet Inter- ORB
Method Protocol as its underlying Protocol as its underlying remoting
remoting protocol. protocol.
III-Architecute of CORBA
The CORBA architecture for distributed objects shares many features with the
architecture used by java RMI.A description of a remote object is used to
generate a client stub interface and server skeleton interface for the object. A
client application invokes methods on a remote object using the client stub,
whereas the server skeleton for the object is asked to invoke the method on the
object itself
The majorcomponents of the CORBA architecture include IDL,ORB and
object Adapter, Naming services and Inter-ORB communication protocol.
IDL defines the CORBA interfaces.
ORB and object adapter are responsible for handling all interaction
between remote object and application that use them.
Naming services provides remote client to find remote object on the
network.
The Inter-ORB protocols handle the low-level communication between
processes in a CORBA context.
The CORBA naming services provides a naming structure for remote objects.
The CORBA naming services is one of the naming and directory services
provided by JNDI.
The naming tree always starts with a root node,and sub nodes of the object tree
can be created by an application.
Actual objects are stored by name at the leaves of the tree
Eg:
The full name of the object labeled Fred is -living things,animal,man,fred in that
order.
Living things
animals
man ox
fred
Each branch in the directory tree is called naming context.
Each node in the names directory is represented by an
org.omg.COSNaming.NamingContext object.
We can get a reference to the root content by using
resolve_initial_refernce() method.
Once we can have the reference we can perform lookups of CORBA
object,as well as register your own corba objects with the naming
services.