[prev in list] [next in list] [prev in thread] [next in thread] 

List:       omniorb-list
Subject:    [omniORB] Antw: Re:  How to destroy objects
From:       "Stefan Walter" <Stefan.Walter () lisec ! com>
Date:       2013-07-03 9:42:15
Message-ID: 51D42A370200001000049631 () mx1 ! lisec ! com
[Download RAW message or body]

[Attachment #2 (multipart/alternative)]


Dear Duncan,
 
I mean how to release the object reference on client side.
 
Regards,
Stefan

>>> 


Von: Duncan Grisby <duncan@grisby.org>
An:Stefan Walter <Stefan.Walter@lisec.com>
CC:<omniorb-list@omniorb-support.com>
Datum: 03.07.2013 13:38
Betreff: Re: [omniORB] How to destroy objects
On Tue, 2013-07-02 at 15:18 +0200, Stefan Walter wrote:

> how do I destroy objects in omniORB which are not longer required.

Can you clarify what you are talking about destroying?  There are at
least two things you might mean:

1. On the client side, release the object reference.
2. On the server side, deactivate the object and delete the servant.

In CORBA, those two things are totally separate concerns. Client
object
references are reference counted, and the Echo_var holder
automatically
releases its reference when it goes out of scope.

The lifetime of server-side object activations is completely
unaffected
by whether any clients hold object references. If you want to get rid
of
the server-side objects, you must write server-side code to do so. It
is
common to define a destroy() method in your IDL, for example, so a
client can dispose of an object when it has finished with it. To
deactivate an object, you call deactivate_object on the POA it is
activated within.

In more complex situations, you might want to implement some sort of
evictor or timeout that automatically deactivates objects that are no
longer in use. It all depends upon what you want the semantics to be.

Cheers,

Duncan.

-- 
-- Duncan Grisby		 --
  -- duncan@grisby.org     --
   -- http://www.grisby.org --




__________________________________________
The content of this e-mail is confidential and restricted for the use of
the intended recipient only. If you are not the intended recipient
please inform the sender immediately and delete this e-mail and any
attachments. We cannot accept liability for any damage incurred as a
result of software viruses and advise that you carry out your own virus
checks before opening any attachment.

Der Inhalt dieses E-Mails ist vertraulich und für die alleinige
Verwendung durch den beabsichtigten Empfänger bestimmt. Falls Sie nicht
der beabsichtigte Empfänger sind, bitten wir Sie den Absender umgehend
zu informieren und dieses E-Mail samt angeschlossenen Dateien zu
löschen. Wir können keine Haftung für allfällige Schäden übernehmen,
die aufgrund von Software-Viren entstehen, und empfehlen Ihnen, selbst
Virenprüfungen durchzuführen, bevor Sie eine Anlage öffnen.

[Attachment #5 (text/html)]

<HTML><HEAD>
<META content="text/html; charset=utf-8" http-equiv=Content-Type>
<META name=GENERATOR content="MSHTML 10.00.9200.16618"></HEAD>
<BODY style="FONT: 10pt Segoe UI; MARGIN: 4px 4px 1px">
<DIV>Dear Duncan,</DIV>
<DIV>&nbsp;</DIV>
<DIV>I mean how to release the object reference on client side.</DIV>
<DIV>&nbsp;</DIV>
<DIV>Regards,</DIV>
<DIV>Stefan<BR><BR>&gt;&gt;&gt; </DIV>
<TABLE style="FONT-SIZE: 1em; MARGIN: 0px 0px 0px 15px" bgColor=#f3f3f3 border=0>
<TBODY>
<TR>
<TD>
<DIV style="PADDING-LEFT: 7px; BORDER-LEFT: #050505 1px solid">
<TABLE style="FONT: 9pt Segoe UI" bgColor=#f3f3f3>
<TBODY>
<TR vAlign=top>
<TD><STRONG>Von: </STRONG></TD>
<TD>Duncan Grisby &lt;duncan@grisby.org&gt;</TD></TR>
<TR vAlign=top>
<TD><STRONG>An:</STRONG></TD>
<TD>Stefan Walter &lt;Stefan.Walter@lisec.com&gt;</TD></TR>
<TR vAlign=top>
<TD><STRONG>CC:</STRONG></TD>
<TD>&lt;omniorb-list@omniorb-support.com&gt;</TD></TR>
<TR vAlign=top>
<TD><STRONG>Datum: </STRONG></TD>
<TD>03.07.2013 13:38</TD></TR>
<TR vAlign=top>
<TD><STRONG>Betreff: </STRONG></TD>
<TD>Re: [omniORB] How to destroy objects</TD></TR></TBODY></TABLE>On Tue, 2013-07-02 \
at 15:18 +0200, Stefan Walter wrote:<BR><BR>&gt; how do I destroy objects in omniORB \
which are not longer required.<BR><BR>Can you clarify what you are talking about \
destroying?&nbsp; There are at<BR>least two things you might mean:<BR><BR>1. On the \
client side, release the object reference.<BR>2. On the server side, deactivate the \
object and delete the servant.<BR><BR>In CORBA, those two things are totally separate \
concerns. Client object<BR>references are reference counted, and the Echo_var holder \
automatically<BR>releases its reference when it goes out of scope.<BR><BR>The \
lifetime of server-side object activations is completely unaffected<BR>by whether any \
clients hold object references. If you want to get rid of<BR>the server-side objects, \
you must write server-side code to do so. It is<BR>common to define a destroy() \
method in your IDL, for example, so a<BR>client can dispose of an object when it has \
finished with it. To<BR>deactivate an object, you call deactivate_object on the POA \
it is<BR>activated within.<BR><BR>In more complex situations, you might want to \
implement some sort of<BR>evictor or timeout that automatically deactivates objects \
that are no<BR>longer in use. It all depends upon what you want the semantics to \
be.<BR><BR>Cheers,<BR><BR>Duncan.<BR><BR>-- <BR>-- Duncan \
Grisby&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; --<BR>&nbsp; -- \
duncan@grisby.org&nbsp;&nbsp;&nbsp;&nbsp; --<BR>&nbsp;&nbsp; -- <A \
href="http://www.grisby.org">http://www.grisby.org</A> \
--<BR><BR><BR><BR></DIV></TD></TR></TBODY></TABLE><BR>

    <div>
      <font size="1" color="#999999" face="Nimbus Sans \
L">______________________________ </font><font size="1" face="Nimbus Sans \
                L"><br></font><font size="1" color="#999999" face="Nimbus Sans L">The \
                
      content of this e-mail is confidential and restricted for the use of the 
      intended recipient only. If you are not the intended recipient please 
      inform the sender immediately and delete this e-mail and any attachments. 
      We cannot accept liability for any damage incurred as a result of 
      software viruses and advise that you carry out your own virus checks 
      before opening any attachment.</font><font size="1" face="Nimbus Sans \
                L"><br><br></font><font size="1" color="#999999" face="Nimbus Sans \
                L">Der 
      Inhalt dieses E-Mails ist vertraulich und f&#252;r die alleinige Verwendung 
      durch den beabsichtigten Empf&#228;nger bestimmt. Falls Sie nicht der 
      beabsichtigte Empf&#228;nger sind, bitten wir Sie den Absender umgehend zu 
      informieren und dieses E-Mail samt angeschlossenen Dateien zu l&#246;schen. 
      Wir k&#246;nnen keine Haftung f&#252;r allf&#228;llige Sch&#228;den \
                &#252;bernehmen, die aufgrund 
      von Software-Viren entstehen, und empfehlen Ihnen, selbst Virenpr&#252;fungen 
      durchzuf&#252;hren, bevor Sie eine Anlage &#246;ffnen.</font>
    </div>
  </BODY></HTML>



_______________________________________________
omniORB-list mailing list
omniORB-list@omniorb-support.com
http://www.omniorb-support.com/mailman/listinfo/omniorb-list


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic