CCM: The CORBA Component Model Portable Object Adapter (POA) - - PowerPoint PPT Presentation

ccm
SMART_READER_LITE
LIVE PREVIEW

CCM: The CORBA Component Model Portable Object Adapter (POA) - - PowerPoint PPT Presentation

DF14900 Software Engineering TDDD05 Component-Based Software CCM: The CORBA Component Model Portable Object Adapter (POA) revisited Portable Object Adapter (POA) revisited CORBA Objects CORBA Objects CORBA Component Model


slide-1
SLIDE 1

Christoph Kessler, IDA, Linköpings universitet, 2010.

DF14900 Software Engineering TDDD05 Component-Based Software

CCM:

The CORBA Component Model

 Portable Object Adapter (POA) revisited  CORBA Objects  CORBA Component Model (CORBA 3.0)

Szyperski: Component Software 2e, Chapter 13.3

 Portable Object Adapter (POA) revisited  CORBA Objects  CORBA Component Model (CORBA 3.0)

Szyperski: Component Software 2e, Chapter 13.3

slide-2
SLIDE 2

2

DF14900 / TDDD05

  • C. Kessler, IDA, Linköpings universitet.

Portable Object Adapter (POA) revisited

CORBA object = Object ID + servant instance + mapping

Client Server POA – ”MyPOA” policies ... ”Fred” ”Anna” Active Object Map

maps object IDs to servants

Servant Servant Object references

Image adapted from: F. Bolton: Pure CORBA, Sams Publ., 2002.

slide-3
SLIDE 3

3

DF14900 / TDDD05

  • C. Kessler, IDA, Linköpings universitet.

Confguring a POA

POA policy type Allowed values RootPOA policy Child POA default pol. ThreadPolicy ORB_CTRL_MODEL (multithr.) SINGLE_THREAD_MODEL LifeSpanPolicy TRANSIENT PERSISTENT IdAssignmentPol. SYSTEM_ID USER_ID IDUniquenessPol. UNIQUE_ID MULTIPLE_ID RequestProcess- ingPolicy

USE_ACTIVE_OBJECT_MAP_ONLY USE_DEFAULT_SERVANT USE_SERVANT_MANAGER

ServantRetention- Policy RETAIN NON_RETAIN ImplicitActivation- Policy NO_IMPLICIT_ACTIVATION IMPLICIT_ACTIVATION

slide-4
SLIDE 4

4

DF14900 / TDDD05

  • C. Kessler, IDA, Linköpings universitet.

Confguring a POA, continued

Remark: Not all theoretically possible combinations make sense / are permitted.

RootPOA: The default POA when the server comes up

Customized child POA’s can be created with different policies

slide-5
SLIDE 5

5

DF14900 / TDDD05

  • C. Kessler, IDA, Linköpings universitet.

Life span of CORBA Objects

Controlled by POA life span policy

 Transient objects

 Lifetime bounded by

 lifetime of server process that created it  and of its POA

 Usually, short-lived

 Persistent objects

 Lifetime unbounded  Its creating server can be stopped and restarted multiple times  Dormant when its POA is destroyed;

reactivated when its server is restarted and POA is reinstantiated

 State stored in a database

slide-6
SLIDE 6

6

DF14900 / TDDD05

  • C. Kessler, IDA, Linköpings universitet.

Types of CORBA Objects (1)

Session objects

usually short-lived, non-persistent

Client Server POA –”SessionPOA” TRANSIENT, ... ”Fred” Servant 3. Create IOR 2. Activate servant 1. Create servant

Image adapted from: F. Bolton: Pure CORBA, Sams Publ., 2002.

slide-7
SLIDE 7

7

DF14900 / TDDD05

  • C. Kessler, IDA, Linköpings universitet.

Types of CORBA Objects (2)

Entity objects

usually long-lived, persistent

Client Server POA – ”EntityPOA” PERSISTENT, ... ”Fred” Servant 4. Create IOR 3. Activate servant 2. Create servant 1. Create DB record DB

state

Image adapted from: F. Bolton: Pure CORBA, Sams Publ., 2002.

slide-8
SLIDE 8

8

DF14900 / TDDD05

  • C. Kessler, IDA, Linköpings universitet.

Types of CORBA Objects (3)

Factory Object

Create, fnd and destroy other objects Perform steps 1, 2, 3 (, 4) as above

for session / entity objects

Can itself be a session or entity object

slide-9
SLIDE 9

9

DF14900 / TDDD05

  • C. Kessler, IDA, Linköpings universitet.

CORBA Component Model (CCM)

 Abstraction of CORBA object with its environment  Container

 Abstraction of POA functionality

 Life cycle management

 Provision of CORBA Services for enterprise applications

 security, transaction, event service  Simplifed interfaces covering most commonly used features

 Support for ready-made components

 Confguration and assembly

 Separate component logic and CORBA functionality

 e.g., hide house-keeping code (POA object creation, life cycle

management for CORBA objects etc.)

 EJB (2.0) look-and-feel

 Basic components: Fully EJB compatible

slide-10
SLIDE 10

10

DF14900 / TDDD05

  • C. Kessler, IDA, Linköpings universitet.

CORBA Component Model Architecture

Home Home Component Component Component

manages manages

home: factory object to create, fnd, remove component instances

Container

facet: provided external inter- faces to client receptacle: registry for component references – ”uses” relation made explicit component: basic building block for server application container: environment that supports components callback interfaces for container to notify com- ponent about events etc.

Image adapted from: F. Bolton: Pure CORBA, Sams Publ., 2002.

slide-11
SLIDE 11

11

DF14900 / TDDD05

  • C. Kessler, IDA, Linköpings universitet.

CORBA Component Model

Basic components: Fully EJB compatible and interoperable

Extended components: beyond EJB, e.g. ports

Ports: Special sorts of interfaces, grouped together

Facets Receptacles Event sources Event sinks

Confguration interfaces with setters and getters

Extended IDL (Component IDL, CIDL)

New elements: component, interface, home, fnder,

factory ...

slide-12
SLIDE 12

12

DF14900 / TDDD05

  • C. Kessler, IDA, Linköpings universitet.

CORBA Component Categories

Session components (cf. EJB stateful session beans)

transient state, transient identity

Service components (cf. EJB stateless session beans)

no state, no identity

Entity components (cf. EJB entity beans)

persistent state persistent identity, automatically visible to clients

Process components

persistent state persistent identity, not automatically visible to clients