[omniORB] BOA -> POA questions

Masaaki Sekiya sekiya@nagoya.ydc.co.jp
Mon, 17 Jul 2000 20:04:17 +0900 (JST)


> > Looking through your example code in
> > http://www.uk.research.att.com/omniORB/doc/3.0/omniORB/omniORB002.html#toc9
> > 
> > I find a call to myecho->_remove_ref() which I don't understand.
> > Given that the call to _this() increments the ref counter and sets it

I am understanding as below,
_this() increments the ref counter with omniORB2.8.
but _this() doesn't increment the ref counter with omniORB3.
The reason why I am understanding like this is that
I checked the value of "myecho->pd_refCount" before and after 
"myecho->_this()" , then the value was not changed.
Is it right ?

> > to 1, I would think that a call to 'deactivate_object' sets it back to
> > 0, resulting in the deletion.
> 
> When a servant is created it has a reference count of 1.  When you
> activate it, it becomes 2.  You then call _remove_ref() to take it back to
> 1.  When you deactivate the servant, it will go to zero and be deleted
> (once all outstanding requests have completed).

If _this() doesn't change the ref counter,
it seems to me that both Echo_var and POA refer to a servant 
after _remove_ref() is called.
Am I misunderstanding ? 

Masaaki Sekiya