component architecture (corba – rmi) -shalini pradhan

14
Component Component Architecture Architecture (CORBA – RMI) (CORBA – RMI) -Shalini Pradhan -Shalini Pradhan

Upload: bertina-bradley

Post on 12-Jan-2016

213 views

Category:

Documents


0 download

TRANSCRIPT

Component ArchitectureComponent Architecture(CORBA – RMI)(CORBA – RMI)

-Shalini Pradhan-Shalini Pradhan

Common ArchitecturesCommon Architectures Data Flow SystemsData Flow Systems

Batch Sequential & Control LoopsBatch Sequential & Control Loops Pipes and FiltersPipes and Filters

Call and Return SystemsCall and Return Systems Main Programs & SubroutinesMain Programs & Subroutines Object Oriented SystemsObject Oriented Systems

Independent ComponentsIndependent Components Communicating Processes & Event SystemsCommunicating Processes & Event Systems

Data – Centered Systems (Repositories)Data – Centered Systems (Repositories) Databases & BlackboardsDatabases & Blackboards

Virtual MachinesVirtual Machines Rule based systems Rule based systems

Object Oriented ArchitectureObject Oriented Architecture

Component ArchitectureComponent Architecture

ComponentComponent Independent unit of SoftwareIndependent unit of Software It satisfies a set of behavior rules It satisfies a set of behavior rules

Component ArchitectureComponent Architecture Specifices set of interfaces and rules of Specifices set of interfaces and rules of

interaction interaction

[[http://www-unix.mcs.anl.gov/~curfman/cca/web/cca_paper.htmlhttp://www-unix.mcs.anl.gov/~curfman/cca/web/cca_paper.html]]

How do Components Interact?How do Components Interact?Components interact via clearly specified interfacesComponents interact via clearly specified interfaces

CustomerInterface

Focus on individual interfaces- precise external behavior (provided + required)- all implementation aspects completely hidden

Focus on individual interfaces- precise external behavior (provided + required)- all implementation aspects completely hidden

iGetMoney()

Retailer

WholesaleriReceiveOrder()

iOrderInventory()

Supplier

iReceiveInventory()

iReceiveItem()

Component Architecture Component Architecture StandardsStandards

CORBACORBA CORBA is a distributed object specification supported by the OMG CORBA is a distributed object specification supported by the OMG

(Object Management Group), a consortium of over eight hundred (Object Management Group), a consortium of over eight hundred partners.partners.

Java BeansJava Beans JavaBeans and Enterprise JavaBeans (EJB) are component architectures JavaBeans and Enterprise JavaBeans (EJB) are component architectures

developed by Sun and its partners.developed by Sun and its partners.

COM COM is Microsoft's component standard that forms the basis for interoperability is Microsoft's component standard that forms the basis for interoperability

among all Window-based applications.among all Window-based applications. Java RMI (Remote Method Invocation)Java RMI (Remote Method Invocation)

The Java remote method invocation system described in this specification The Java remote method invocation system described in this specification has been specifically designed to operate in the Java environment. has been specifically designed to operate in the Java environment.

CORBACORBA

http://students.cec.wustl.edu/~dm9/DCA/CORBA.htm

AdvantagesAdvantages CORBA supports many existing languages. CORBA supports many existing languages.

CORBA also supports mixing these languages CORBA also supports mixing these languages within a single distributed application. within a single distributed application.

CORBA supports both distribution and Object CORBA supports both distribution and Object Orientation.Orientation.

CORBA is an industry standard. CORBA is an industry standard. CORBA provides a high degree of CORBA provides a high degree of

interoperability. This insures that distributed interoperability. This insures that distributed objects built on top of different CORBA objects built on top of different CORBA products can communicate. products can communicate.

Over 600 companies back CORBA, including Over 600 companies back CORBA, including hardware companies, software companies, and hardware companies, software companies, and cable companies, phone companies, banks, cable companies, phone companies, banks, etc.etc.

LimitationsLimitations Not freeNot free

costs can be substantialcosts can be substantial developer licenses ( $800+ per developer)developer licenses ( $800+ per developer) runtime licenses (cost varies with vendor)runtime licenses (cost varies with vendor) standardized extensions (“Object services” inOMG standardized extensions (“Object services” inOMG

speak) add more costsspeak) add more costs Harder to use Harder to use

no support for detecting software version mismatchesno support for detecting software version mismatches runtime, sometimes resulting in silent errorsruntime, sometimes resulting in silent errors

Add-on to the languageAdd-on to the language[http://www.ociweb.com/javasig/knowledgebase/February1998/RMI_CORBA.pdf][http://www.ociweb.com/javasig/knowledgebase/February1998/RMI_CORBA.pdf]

ApplicationApplication

Manage constant diversity - Heterogeneous Manage constant diversity - Heterogeneous environmentenvironment

Good for accessing legacy systemsGood for accessing legacy systems especially if Java is not supported on the legacy especially if Java is not supported on the legacy

platformplatform Good for extending existing CORBA-based Good for extending existing CORBA-based

systems with Javasystems with Java Good for leveraging expertise in other languagesGood for leveraging expertise in other languages

as long as there is a CORBA binding for that languageas long as there is a CORBA binding for that language

Java RMIJava RMI Java language's RMI system assumes the Java language's RMI system assumes the

homogeneous environment of the Java Virtual homogeneous environment of the Java Virtual Machine, and the system can therefore take Machine, and the system can therefore take advantage of the Java object model whenever advantage of the Java object model whenever possible. possible.

Remote method invocationRemote method invocation (RMI) is the action of (RMI) is the action of invoking a method of a remote interface on a invoking a method of a remote interface on a remote object. Most importantly, a method remote object. Most importantly, a method invocation on a remote object has the same syntax invocation on a remote object has the same syntax as a method invocation on a local object.as a method invocation on a local object. [[http://java.sun.com/products/jdk/1.1/docs/guide/rmi/spec/rmi-objmodel.doc.html#213http://java.sun.com/products/jdk/1.1/docs/guide/rmi/spec/rmi-objmodel.doc.html#213 ]]

Java RMIJava RMI The interfaces and classes that are responsible for The interfaces and classes that are responsible for

specifying the remote behavior of the RMI system are specifying the remote behavior of the RMI system are defined in the defined in the java.rmijava.rmi and the and the java.rmi.server java.rmi.server java.rmi.registryjava.rmi.registry packages. packages.

  

Client VM

stub

RMI Registry

skeleton

OBJ

Server VM

AdvantagesAdvantages Simple to use - sending objectsSimple to use - sending objects

implement “Serializable” interfaceimplement “Serializable” interface optionally specify codebaseoptionally specify codebase automatic version mismatch detectionautomatic version mismatch detection

Integrated into platformIntegrated into platform remote method calls are nearly identical to normal remote method calls are nearly identical to normal

method callsmethod calls distributed garbage collection preserves automatic distributed garbage collection preserves automatic

memory managementmemory management Can pass objectsCan pass objects Supports Distributed ProcessingSupports Distributed Processing

LimitationsLimitations

Works in only Java EnvironmentWorks in only Java Environment Not a full featured MiddlewareNot a full featured Middleware No mechanism for object descriptionNo mechanism for object description Server agentsServer agents