[omniORB] Client side connection caching

Duncan Grisby duncan at grisby.org
Mon Jul 11 20:18:36 BST 2005


On Thursday 30 June, "Al Slater" wrote:

> According to the user guide : "The first time the client makes a call to
> a particular address space, the ORB opens a suitable connection to the
> remote address space (based on the client transport rule as described in
> section 8.7.1). After the reply has been received, the ORB caches the
> open network connection, ready for use by another call."
> 
> Is this connection cached even after the last reference to a servant has
>  gone away?  If so, is there any way to disable this caching?

The connection is kept. The reason for that is that some applications
repeatedly receive objects in the same address space, deal with them
then drop them. Think of an operation that takes a callback object as
its argument -- if one client keeps calling it, you definitely don't
want to drop the connection each time the callback object reference is
released.

If you want to change the behaviour, look at giopRope::decrRefCount() in
giopRope.cc and the code in giopStrand.cc. You need to cause the strands
to be closed immediately when the rope's reference count goes to zero.

Cheers,

Duncan.

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



More information about the omniORB-list mailing list