A Policy Driven CORBA Template Library - Update

This is a discussion on A Policy Driven CORBA Template Library - Update within the Object forums in Theory and Concepts category; I have overhauled my original paper (A Policy Driven CORBA Template Library). It presents a library that facilitates large CORBA application development, to be used with TAO (and hopefully other ORBs in the future). The new revision addresses many of the points reviewers have brought up, provides clearer examples, and reflects the changes to the CTL library in the interim. The updated paper can be found at http://www.astro.ufl.edu/~dan/ctl.pdf As before feedback, criticism and suggestions are welcome. The library is freely available under a BSD license (by request for now, until i setup a sourceforge project or host it elsewhere). The ...

Go Back   Application Development Forum > Theory and Concepts > Object

Object Mix

Register FAQ Calendar Search Today's Posts Mark Forums Read
  #1  
Old 09-30-2003, 12:15 AM
Jeff Mirwaisi
Guest
 
Default A Policy Driven CORBA Template Library - Update

I have overhauled my original paper (A Policy Driven CORBA Template
Library). It presents a library that facilitates large CORBA application
development, to be used with TAO (and hopefully other ORBs in the future).
The new revision addresses many of the points reviewers have brought up,
provides clearer examples, and reflects the changes to the CTL library in
the interim. The updated paper can be found at

http://www.astro.ufl.edu/~dan/ctl.pdf

As before feedback, criticism and suggestions are welcome.

The library is freely available under a BSD license (by request for now,
until i setup a sourceforge project or host it elsewhere). The
WidgetFactory examples in the paper, using basic CORBA and the CTL
templates, as well as a simple client app are also available.

Thanks,
Jeff Mirwaisi
Reply With Quote
  #2  
Old 10-01-2003, 04:08 PM
Jeff Mirwaisi
Guest
 
Default Re: A Policy Driven CORBA Template Library - Update

The CTL library can be found at:

http://astro.ufl.edu/~dan/ctl.zip

and the examples in the paper at

http://astro.ufl.edu/~dan/paper_examples.zip
Reply With Quote
  #3  
Old 10-09-2003, 12:24 PM
Michael McKnerney
Guest
 
Default Re: A Policy Driven CORBA Template Library - Update



Jeff Mirwaisi wrote:

> I have overhauled my original paper (A Policy Driven CORBA Template
> Library). It presents a library that facilitates large CORBA application
> development, to be used with TAO (and hopefully other ORBs in the future).
> The new revision addresses many of the points reviewers have brought up,
> provides clearer examples, and reflects the changes to the CTL library in
> the interim. The updated paper can be found at
>
> http://www.astro.ufl.edu/~dan/ctl.pdf
>
> As before feedback, criticism and suggestions are welcome.
>


I was curious why having a servant inherit from a set of nested templates was
better than just directly inheriting from those same classes directly?

Also, is it possible to shared the same poa across servants? it looked like
your approach was to have each servant create its own poa?

To be honest, I' still new to meta programming so I apologize if I'm way off
and have yet to gain appreciation of what you've provided.

Thanks,
Mike

>
> The library is freely available under a BSD license (by request for now,
> until i setup a sourceforge project or host it elsewhere). The
> WidgetFactory examples in the paper, using basic CORBA and the CTL
> templates, as well as a simple client app are also available.
>
> Thanks,
> Jeff Mirwaisi


Reply With Quote
  #4  
Old 10-09-2003, 02:13 PM
Jeff Mirwaisi
Guest
 
Default Re: A Policy Driven CORBA Template Library - Update

Michael McKnerney <michael.mcknerney@baesystems.com> wrote in
news:3F858BBD.B16A72BB@baesystems.com:

>
>
> Jeff Mirwaisi wrote:
>
>> I have overhauled my original paper (A Policy Driven CORBA Template
>> Library). It presents a library that facilitates large CORBA
>> application development, to be used with TAO (and hopefully other
>> ORBs in the future). The new revision addresses many of the points
>> reviewers have brought up, provides clearer examples, and reflects
>> the changes to the CTL library in the interim. The updated paper can
>> be found at
>>
>> http://www.astro.ufl.edu/~dan/ctl.pdf
>>
>> As before feedback, criticism and suggestions are welcome.
>>

>
> I was curious why having a servant inherit from a set of nested
> templates was better than just directly inheriting from those same
> classes directly?
>


I'm not sure which nested template useage youre refering to, but there are
a couple reasons that linear inheritance hierarchies are sometimes prefered
to multiple inheritance.

One: derived types can delegate to base types to continue processing

struct EmptyType {};
template <typename B = EmptyType> struct A : B { void f() {B::f();}};
template <> struct A<EmptyType> {void f() {}};

struct D : A<A<A<> > > {};
void g() {D d; d.f();}

A MI approach to the above would require D know how many base types will
want to participate in the invocation of f ahead of time

Two: linear hierarchies allow us to fullfile a base types interface
requirements

struct A {virtual void f()=0;};
struct B {virtual void f()=0;};
template <typename T> struct I : T {void f() {}};

struct C : I<A> {}; //C is a complete type satisfying interface A
struct D : I<B> {}; //D is a complete type satisfying interface B

Sharing the implementation of f accross different concrete types that
inherit from different pure base types isnt possible with MI, unless the
concrete type provides a function with a matching signature that delegates
to the MI base

struct MI {void f() {}};
struct E : A,MI {void f() {MI::f();}};

Three: There is no built in c++ aprroach to variable template argument
lists, so linear hierarchies provide a convenient way to deliver more
template argument types to the servant templates. Type lists (alexandrescu)
are another option but they are a bit more cumbersome to use, and also use
nestted templates to provide a list of types as a single type.

There are a number of corolaries to the above, that I wont go into here. If
you want to know why a particular element of the library uses nested
templates instead of MI let me know and I'll try to provide a rationale.

> Also, is it possible to shared the same poa across servants? it
> looked like your approach was to have each servant create its own poa?
>


Yes its certainly possible, and you definetly do not need to use a distinct
POA per servant. If the POA policy is POAEmpty or Root then the servant
activation process won't attempt to create a POA for you. If the policy is
POAEmpty then you are responsible for providing the POA the servant should
e activated with prior to the call to createServant by either manualy
creating a new poa or simply setting the POA to an allready created POA. If
the servant type is hosting the POA_var (uses CTL::MIX::Host::POA) then a
set_poa method is available in the servants interface, if the POA is
reachable via delegate then your delegate which maintains the POA_var to be
used must allow you to set the POA_var. If you specify Root as the POA
policy then the RootPOA will be used to activate the servant.Notice that
the example in the paper uses the same POA for every Widget activated.

I hope that clears up some of your questions. If you have specific
questions about why I used a particular technique I'll try to answer them.
If you want a thorough look at metaprogramming I suggest Modern C++ Design,
Andrei Alexandrescu, and C++ Templates: The Complete Guide, David
Vandervoorde and Nicolai Josuttis, both excellent books on the subject.

-Jeff Mirwaisi

> To be honest, I' still new to meta programming so I apologize if I'm
> way off and have yet to gain appreciation of what you've provided.
>
> Thanks,
> Mike
>
>>
>> The library is freely available under a BSD license (by request for
>> now, until i setup a sourceforge project or host it elsewhere). The
>> WidgetFactory examples in the paper, using basic CORBA and the CTL
>> templates, as well as a simple client app are also available.
>>
>> Thanks,
>> Jeff Mirwaisi

>
>


Reply With Quote
  #5  
Old 10-09-2003, 04:10 PM
Jeff Mirwaisi
Guest
 
Default Re: A Policy Driven CORBA Template Library - Update

POAEmpty should be POAPolicy::Empty
Reply With Quote
Reply


Thread Tools
Display Modes


All times are GMT -5. The time now is 07:48 AM.


Powered by vBulletin® Version 3.7.2
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.2.0
vB Ad Management by =RedTyger=

In an effort to better serve ads to our visitors, cookies are used on objectmix.com. For more information, check out our Privacy Policy.