1 eloadas corba 5

Upload: midhun-p-gopi

Post on 09-Apr-2018

223 views

Category:

Documents


0 download

TRANSCRIPT

  • 8/7/2019 1 Eloadas CORBA 5

    1/29

    Common Object Request

    Broker Architecture(CORBA)

    By:

    Sunil GopinathDavid Watkins

  • 8/7/2019 1 Eloadas CORBA 5

    2/29

    Introduction

    What is the purpose / goals of CORBA?

    How to meet goals?

    Example

    Conclusion

  • 8/7/2019 1 Eloadas CORBA 5

    3/29

    What is the purpose / goals of CORBA?

    Enable the building of plug and play

    component software environment

    Enable the development of portable, object

    oriented, interoperable code that is

    hardware, operating system, network, and

    programming language independent

  • 8/7/2019 1 Eloadas CORBA 5

    4/29

    How to meet goals?

    Interface Definition Language (IDL)

    Object Request Broker (ORB)

  • 8/7/2019 1 Eloadas CORBA 5

    5/29

    Interface Definition Language (IDL)

    Language Independence

    Defines Object Interfaces

    Hides underlying object implementation

    Language mappings exist for C, C++, Java,

    Cobol, Smalltalk, and Ada

  • 8/7/2019 1 Eloadas CORBA 5

    6/29

    Interface Definition Language (IDL)

    module

    {

    interface [:inheritance]

    {;

    ;

    ;

    ;

    [] ()

    [raises exception][context];

    }

    }

    Defines a

    CORBA object

    Defines a

    method

    Defines a container

    (namespace)

  • 8/7/2019 1 Eloadas CORBA 5

    7/29

    IDL Compiler

    IDL

    Definitions

    IDL

    Compiler

    Stubs Skeletons

    1. Define objects usingIDL

    2. Run IDL file throughIDL compiler

    3. Compiler uses languagemappings to generate

    programming language

    specific stubs andskeletons

  • 8/7/2019 1 Eloadas CORBA 5

    8/29

    Object Request Broker (ORB)

    What is it?

    Architecture

    Request Handling

    Scenario

    CORBA Services CORBA Facilities

  • 8/7/2019 1 Eloadas CORBA 5

    9/29

    Application

    What is it?

    Implementation of CORBA specification

    Middleware product

    Conceptual Software Bus

    Hides location and

    implementation detailsabout objects

    Hardware

    OS Drivers

    Middleware

  • 8/7/2019 1 Eloadas CORBA 5

    10/29

    Client / Object Interaction

    Client Obj Impl

    IDL IDL

    ORB

    Client Obj Impl

    IDL IDL

    ORB

    Network

    TCP

    /IP

    OSI

    ATM

    IPX

    TCP

    /IP

    OSI

    ATM

    IPX

  • 8/7/2019 1 Eloadas CORBA 5

    11/29

    ORB Architecture

    Interface

    Repository

    IDL

    Compiler

    Implementation

    Repository

    Client Object (servant)

    ORB Core

    IDLSkeleton

    DSIORB

    Interface

    IDL

    StubDII

    OBJ

    Ref

    GIOP/IOOP

    Object Adapter

  • 8/7/2019 1 Eloadas CORBA 5

    12/29

    Interface Repository

    Interface

    Repository

    Object Adapter

    Database of object definitions

    Contains metadata about each object

    Allows for introspection

    Allows clients to discover interfaces at run-time Used in support of dynamic invocations

  • 8/7/2019 1 Eloadas CORBA 5

    13/29

    IDL Compiler

    IDL

    Compiler

    Object Adapter

    Compiles IDL definition into stubs andskeletons

    Uses OMG specified language mappingsto translate IDL into a language specificimplementation

  • 8/7/2019 1 Eloadas CORBA 5

    14/29

    Implementation Repository

    Implementation

    Repository

    Object Adapter

    Contains information that allows the ORBto locate and activate objectimplementations

    Provides information about the classes aserver supports, the objects that areinstantiated, and their IDs

  • 8/7/2019 1 Eloadas CORBA 5

    15/29

    ORB Core

    ORB CoreGIOP/IOOP

    Object Adapter

    Provides mechanism for transparentlycommunicating client requests to target

    object implementations Makes client requests appear to be local

    procedure calls

    GIOP General Inter-ORB Protocol

    IIOP Internet Inter-ORB Protocol

  • 8/7/2019 1 Eloadas CORBA 5

    16/29

    ORB Interface

    Client Object (servant)

    ORB

    InterfaceObject Adapter

    Provides helper functions Converting object

    references to strings

    Creating argumentlists for requests made

    through DII

  • 8/7/2019 1 Eloadas CORBA 5

    17/29

    IDL Stub

    Static invocationinterface (SII)

    Marshals applicationdata into a commonpacket-levelrepresentation

    Network byte order(little-endian or big-endian)

    Size of data types

    Client

    IDL

    Stub

  • 8/7/2019 1 Eloadas CORBA 5

    18/29

    IDL Skeleton

    Object (servant)

    IDLSkeleton

    Demarshals the

    packet-level

    representation backinto typed data that is

    meaningful to an

    applicationNetwork byte order

    (little-endian or big-endian)

    Size of data types

  • 8/7/2019 1 Eloadas CORBA 5

    19/29

    Dynamic Invocation Interface

    Client

    DII

    Object Adapter

    Dynamically issue requests to objects

    without requiring IDL stubs to be

    linked in

    Clients discover interfaces at run-

    time and learn how to call them

    Steps:

    1. Obtain interface name2. Obtain method description (from

    interface repository)

    3. Create argument list

    4. Create request

    5. Invoke request

  • 8/7/2019 1 Eloadas CORBA 5

    20/29

    Dynamic Skeleton Interface

    Object (servant)

    DSI

    Object Adapter

    Server side analogue to DII

    Allows an ORB to deliverrequests to an object

    implementation that does

    not have compile-time

    knowledge of the type ofobject it is implementing

  • 8/7/2019 1 Eloadas CORBA 5

    21/29

    Object Adapter

    Object (servant)

    IDLSkeleton

    DSI

    Object Adapter

    Accept requests for service on behalf

    of the servers objects

    Demultiplexes requests to the correct

    servant

    Dispatches the appropriate operation

    upcall on the servant

    Registers classes it supports and their

    run-time instances with theimplementation repository

    Portable Object Adapter (POA)

    policies control object behavior

    (ie. LifespanPolicy)

    Instance of the adapter design pattern

  • 8/7/2019 1 Eloadas CORBA 5

    22/29

    Object Reference

    Client Object (servant)OBJRef

    Object Adapter

    Interoperable Object Reference (IOR)

    Uniquely identifies each object Contents

    Type Name (repository ID)

    Protocol and Address Details

    Object Key (object adaptor name, object name)

  • 8/7/2019 1 Eloadas CORBA 5

    23/29

    Request Handling

    ORB POA

    Server Application

    Servants

    POA

    POA

    Incoming

    Request

  • 8/7/2019 1 Eloadas CORBA 5

    24/29

    Scenario

    Interface

    Repository

    IDL

    Compiler

    Implementation

    Repository

    Client Object (servant)OBJRef

    ORB CoreGIOP/IOOP

    IDL

    StubDII

    Object Adapter

    ORB

    Interface

    IDLSkeleton

    DSI

  • 8/7/2019 1 Eloadas CORBA 5

    25/29

    CORBA Services

    Provide basic infrastructure functionality

    Currently there are 15 defined services

    Naming - maps human names to object references(White Pages)

    Event - provides both a push and pull event model

    Object Trader - discover objects based on the services

    they provide (Yellow Pages)

    Transactions allows distributed objects to participate

    in atomic transactions

  • 8/7/2019 1 Eloadas CORBA 5

    26/29

    CORBA Facilities

    Provide higher-level functionality at the application

    level

    Provide standard components that can be used off-the-shelf

    Two Categories

    Horizontal user interface, information management,

    systems management, and task management Vertical domain based, telecommunications, financial

    services

  • 8/7/2019 1 Eloadas CORBA 5

    27/29

    Example

  • 8/7/2019 1 Eloadas CORBA 5

    28/29

    Conclusion

    Distributed object, component architecture

    Real world examples of design patterns

    TAO freeware ORB

    Adapter, Factory, Reactor, Strategy

    Plugable Transports

    CORBA Beans

  • 8/7/2019 1 Eloadas CORBA 5

    29/29

    References

    www.omg.org

    www.cs.wustl.edu/~schmidt/corba.html

    http://www.infosys.tuwien.ac.at/Research/Corba/

    OMG/arch2.htm

    Communications of the ACM, October 1998

    Jeri Edwards, Dan Harkey, and Robert Orfali.Instant CORBA. New York: Wiley Computer

    Publishing, 1997.