[omniORB] Beginner's question about corbaloc
fischer.c at atlas.de
fischer.c at atlas.de
Mon Nov 15 13:50:08 GMT 2004
Hi,
i just found it in http://www.omg.org/docs/formal/03-06-03.pdf,
the current version of the C++ Language Mapping, in chapter
1.37.5. 'Skeleton Operations'. Thanks for pointing that out.
After reading the third chapter i understand what happens in the
case of an already activated servant incarnating exactly one object.
But the last sentence is a bit confusing:
"The POA is gotton by invoking _default_POA() on the servant".
Would this mean that _default_POA() in this situaton returned a POA
other than the root POA, although it is not overriden?
Best Regards
Clemens
-----Ursprüngliche Nachricht-----
Von: omniorb-list-bounces at omniorb-support.com [mailto:omniorb-list-bounces at omniorb-support.com] Im Auftrag von Clarke Brunt
Gesendet: Montag, 15. November 2004 12:36
An: omniORB-list at omniorb-support.com
Betreff: Re: [omniORB] Beginner's question about corbaloc
<fischer.c at atlas.de> wrote:
>Hi Duncan,
>
>thanks for clarifying this point. In chapter 11.6 'Servant IDL Type',
>Henning & Vinoski write that _default_POA() can be overriden to enable
>_this() to activate objects in a POA other than the root POA.
>But this seems only necessary if the object is not already activated.
>
>Where can i find further information on this topic? The POA chapter in
>the OMG CORBA specification doesn't say really much.
>
>Are you sure that what you say applies to other ORBs, too? I feel like
>having had this double activation problem with a quite old version of
>VisiBroker.
I've always used what is stated in the spec "C++ Language Mapping
Specification", as _this() is presumably specific to C++. The PDF I
downloaded from OMG (possibly out of date) is dated June 1999, and says it
aligns with CORBA 2.3.
Section 1.36.5 (Skeleton Operations) appears to say precisely what Duncan
said, with the addition that if you use _this() within a method invocation,
then you get "...the object reference for the target CORBA object it is
incarnating for that request.".
I hadn't previously appreciated the point that (outside a method
invocation), then if the servant only has a single activation, then you'll
get the object reference for that one (rather than possibly inadvertently
causing another activation in another POA). Relying on this sounds a bit
dodgy to me, as it would break if you happened some time later to have
multiple activations. Far better, if you are going to use _this(), and you
are using a POA other than the root POA, to implement _default_POA() to
return the one you want to use.
So: one would hope that what Duncan said applies to other ORBs too. As for
whether or not it does...
--
Clarke Brunt, Principal Software Engineer, Yeoman Navigation
_______________________________________________
omniORB-list mailing list
omniORB-list at omniorb-support.com
http://www.omniorb-support.com/mailman/listinfo/omniorb-list
More information about the omniORB-list
mailing list