[omniORB] Custom Servant Manager in Python

Duncan Grisby duncan at grisby.org
Thu Oct 12 19:49:22 BST 2006


On Tuesday 10 October, "Stephan February" wrote:

> I am trying to implement a custom servant manager in Python as follows:

[...]
> resyn_servman = ResynServantManager()
> resyn_poa = poa.create_POA("RESYN", poaManager, policies)

> resyn_poa.set_servant_manager(resyn_servman._this())

What's happening is that the set_servant_manager call is doing a _narrow
on the ServantManager object behind the scenes, to make sure it is the
right subclass (ServantLocator in your case). The _narrow involves a
CORBA call to the _is_a operation, which goes through the POA. You
haven't activated the Root POA (where the ServantLocator is activated),
so it blocks waiting for you to activate it.

All you need to do is activate the Root POA's POAManager before calling
set_servant_manager, and it will work fine.

Cheers,

Duncan.

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



More information about the omniORB-list mailing list