1 / 52

Introduction to CORBA

Introduction to CORBA. G. Michael Youngblood Artificial Intelligence Laboratory The University of Texas at Arlington. Objectives. CORBA technology introduction CORBA terminology introduction CORBA references introduction CORBA IDL CORBA Applications CORBA Services CORBA demonstration

mio
Download Presentation

Introduction to CORBA

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Introduction to CORBA G. Michael Youngblood Artificial Intelligence Laboratory The University of Texas at Arlington ©2002-2003 G. Michael Youngblood

  2. Objectives • CORBA technology introduction • CORBA terminology introduction • CORBA references introduction • CORBA IDL • CORBA Applications • CORBA Services • CORBA demonstration • Additional information ©2002-2003 G. Michael Youngblood

  3. CORBATechnology Overview ©2002-2003 G. Michael Youngblood

  4. CORBA • Common Object Request Broker Architecture • Specification written and maintained by the Object Management Group (OMG) http://www.omg.org • First Specification: OMAObject Management Architecture ©2002-2003 G. Michael Youngblood

  5. Object Management Architecture • Object: an encapsulated entity with an immutable distinct identity whose services are accessed only through well-defined interfaces. • Interface Categories: general groupings for object interfaces. Conceptually linked by an ORB. ©2002-2003 G. Michael Youngblood

  6. OMA: Interface Categories • Object Services: domain-independent, or horizontally oriented, interfaces used by many distributed object applications.Ex: Naming Service, Trading Service • Domain Interfaces: domain-specific, or vertically oriented, interfaces usu. Industry specific.Ex: Person Identification Service • Application Interfaces: developed specifically for a given application.Ex: your own CORBA applications ©2002-2003 G. Michael Youngblood

  7. OMA interface categories DomainInterfaces DomainInterfaces ApplicationInterfaces DomainInterfaces DomainInterfaces DomainInterfaces Object Request Broker ObjectServices ©2002-2003 G. Michael Youngblood

  8. CORBATerminology Side step.. ©2002-2003 G. Michael Youngblood

  9. CORBA Terminology • CORBA Object: a “virtual” entity capable of being located by an ORB and having client requests invoked on it. • Target Object: within the context of a CORBA request invocation, it is the CORBA object that is the target of that request. • Client: an entity that invokes a request on a CORBA object, • Server: an application in which one or more CORBA objects exist. • Request: an operation invocation on a CORBA object by a client. • Object Reference: a handle used to identify, locate, and address a CORBA object. • Servant: a programming language entity that implements one or more CORBA objects. ©2002-2003 G. Michael Youngblood

  10. CORBATechnology Overview Returning… ©2002-2003 G. Michael Youngblood

  11. OMA realized through CORBA CORBA provides platform-independent programming interfaces and models for portable distributed object-oriented computing applications. ©2002-2003 G. Michael Youngblood

  12. CORBA major features • OMG Interface Definition Language • Language Mappings • Operation invocation and dispatch facilities (static and dynamic) • Object adapters • Inter-ORB Protocol ©2002-2003 G. Michael Youngblood

  13. CORBA Architecture ©2002-2003 G. Michael Youngblood

  14. IDL • Interface Definition Language • Sole purpose is to allow object interfaces to be defined in a manner that is independent of any particular programming language. ©2002-2003 G. Michael Youngblood

  15. Language Mappings • IDL-to-Programming Language mappings are defined. • C, C++, Java, Ada, LISP, XML, COBOL, FORTRAN, Smalltalk, Eiffel, Perl, Python, Tcl, etc. ©2002-2003 G. Michael Youngblood

  16. Operation Invocation and Dispatch Facilities • Static invocation and dispatch • IDL translated into language-specific stubs and skeletons that are compiled into applications. • Dynamic invocation and dispatch • Construction and dispatch of CORBA requests at run time. • Interface and types determined by outside means (e.g., Interface Repository) ©2002-2003 G. Michael Youngblood

  17. Object Adapters • Serve as glue between servants and the ORB • Fulfill 3 requirements • Create object references, which allow clients to address objects • Ensure each target object is incarnated by a servant • Takes requests dispatched by a server-side ORB and further directs them to servants incarnating each of the target objects • POA! ©2002-2003 G. Michael Youngblood

  18. Inter-ORB Protocols • ORB-to-ORB communication (even between different implementations) • GIOP (“gee-op”): General Inter-ORB Protocol • An abstract protocol that specifies transfer syntax and a standard set of message formats to allow independently developed ORBs to communicate over any connection-oriented transport. • IIOP (“eye-op”): Internet Inter-ORB Protocol • GIOP over TCP/IP ©2002-2003 G. Michael Youngblood

  19. IOR • ORB interoperability also requires standardized object reference formats. • Interoperable Object References (IOR) • Standard object reference format ©2002-2003 G. Michael Youngblood

  20. How does it work? • Request Invocation • Object Reference Semantics • Reference Acquisition • Contents of an Object Reference • References and Proxies ©2002-2003 G. Michael Youngblood

  21. Request Invocation • When a client invokes an operation via an object reference, the ORB does the following: • Locates the target object • Activates the server application if the server is not already running • Transmits any arguments for the call to the object • Activates a servant for the object if necessary • Waits for the request to complete • Returns any out and inout parameters and the return value to the client when the call completes successfully • Returns an exception (including any data contained in the exception) to the client when the call fails ©2002-2003 G. Michael Youngblood

  22. Request Invocation Characteristics • The entire request invocation mechanism is completely transparent to the client, to whom it looks like an ordinary method invocation on a local object. • Request characteristics: • Location transparency • Server transparency • Language independence • Implementation independence • Architecture independence • OS independence • Protocol independence • Transport independence ©2002-2003 G. Michael Youngblood

  23. Object Reference Semantics • Every object reference identifies exactly one object instance • Several different references can denote the same object • References can be nil • References can dangle • Reference are opaque (the client is not allowed to look at their contents) • References are strongly typed • References support late binding • References can be persistent • References can be interoperable ©2002-2003 G. Michael Youngblood

  24. Reference Acquisition • Object references are the only way for a client to reach target objects. • How does a client get a server’s object reference? • Bootstrapping • Naming or Trading Service • Command-line or reading a file • Out-of-band method ©2002-2003 G. Michael Youngblood

  25. Repository ID(standardized) Endpoint Info(standardized) Object Key(proprietary) Contents of an Object Reference • Repository ID • Endpoint Info • Object Key ©2002-2003 G. Michael Youngblood

  26. References and Proxies • When a reference is received by a client, the client-side run time instantiates a proxy object in the client’s address space • This proxy is an instance that supplies an interface to the target object to the client. Client Server Proxy SkeletonInstance foo() foo() foo() ObjectReference foo() Servant ©2002-2003 G. Michael Youngblood

  27. Questions? • CORBA Technology Overview • CORBA Terminology ©2002-2003 G. Michael Youngblood

  28. CORBAReferences ©2002-2003 G. Michael Youngblood

  29. OMG’s Document Access Page • OMG Specificationshttp://www.omg.org/technology/documents/index.htm • Key Specifications • Architecture and Specification (CORBA/IIOP) • IDL • Language Mappings • Services ©2002-2003 G. Michael Youngblood

  30. Good Books • The C++ Standard…Advanced CORBA Programming with C++ by Michi Henning and Steve Vinoski\ • Many examples…PURE CORBA by Fintan Bolton ©2002-2003 G. Michael Youngblood

  31. Implementations • Orbacus • OmniORB • MICO • TAO (The ACE ORB) • ORBit • etc. ©2002-2003 G. Michael Youngblood

  32. Questions? • CORBA References ©2002-2003 G. Michael Youngblood

  33. CORBAInterface Definition Language (IDL) ©2002-2003 G. Michael Youngblood

  34. Interface Definiton Languge • Simple language • Mappings to most modern popular programming languages • Compiled into stub and skeleton code by an IDL compiler ©2002-2003 G. Michael Youngblood

  35. IDL Compilation ©2002-2003 G. Michael Youngblood

  36. IDL Simple Example // description of the module AddressBook module AddressBook { interface Person { attribute string name; string sendEMail(in string fromWhom); }; } ; ©2002-2003 G. Michael Youngblood

  37. IDL Data Types ©2002-2003 G. Michael Youngblood

  38. IDL Supports • Constants • Custom types • Attributes • Methods • Structures • Exceptions • Interfaces • Modules ©2002-2003 G. Michael Youngblood

  39. Questions • CORBA IDL ©2002-2003 G. Michael Youngblood

  40. CORBAApplications ©2002-2003 G. Michael Youngblood

  41. General CORBA Application Development • Determine your application's objects and define their interfaces in IDL • Compile your IDL definitions into C++ stubs and skeletons • Declare and implement C++ servant classes that can incarnate your CORBA objects • Write a server main program • Compile and link your server implementation files with the generated stubs and skeletons to create your server executable • Write, compile, and link your code together with generated stubs ©2002-2003 G. Michael Youngblood

  42. Examples • Coming soon… • Please hold questions until demonstration ©2002-2003 G. Michael Youngblood

  43. CORBAServices ©2002-2003 G. Michael Youngblood

  44. CORBA Services • OMG Naming Service • Basically, DNS for IORs • OMG Trading Service • Service discovery • OMG Event Service • Broadcast events • Interface Repository • Time Service • etc. ©2002-2003 G. Michael Youngblood

  45. Questions? • CORBA Services ©2002-2003 G. Michael Youngblood

  46. CORBADemonstration ©2002-2003 G. Michael Youngblood

  47. CORBA Examples • Simple Client-Server • Advanced Client-Server • Advanced Client-Server using NameService • Advanced Client-Server using NameService invoking a Callback ©2002-2003 G. Michael Youngblood

  48. Questions? • CORBA Applications • CORBA demonstrations ©2002-2003 G. Michael Youngblood

  49. AdditionalInformation Are there any questions? ©2002-2003 G. Michael Youngblood

  50. Questions Any other questions? ©2002-2003 G. Michael Youngblood

More Related