[PolyORB-users] Handling signals

Frédéric Praca frederic.praca at free.fr
Sun Mar 31 11:58:18 CEST 2013


Le Sat, 30 Mar 2013 12:24:46 +0000,
Graham Stark <graham.stark at virtual-worlds.biz> a écrit :

> Hi,
> 
> > Hello guys,
> > I would like to know how I can handle signals to perform sort of
> > cleanup code on SIGINT.
> > To be more precise, I have a kind of load balancer object which
> > holds references to servant objects. These latter register
> > themselves against the balancer. When the servant object get a
> > SIGINT, I attached a handler to cleanly unregister it from the
> > balancer. The problem is that I get this kind of message on the
> > servant part : ^CUnregistering servant
> > polyorb.orb_controller: no event source to monitor
> > polyorb.orb: ORB.Run got exception:
> > polyorb.orb: Exception name: PROGRAM_ERROR
> > Message: dead lock detected
> > 
> > And then I have to kill my servant and the balancer doesn't know
> > that the servant is gone.
> > 
> > Is there a specific way to do this kind of thing ?
> > 
> 
> There's an example of what I think you're after here:
> 
> http://www.pegasoft.ca/resources/boblap/14.html
> 
> (section 14.3). 
> 
> I use something based on this to shut down connection pools in an AWS
> application, and it works quite well.
Well, that's exactly the page I looked at to implement signal handling
but it doesn't seem to work with PolyORB as the exception message above
mentions. For a unknwon reason, it semms that the ORB is shut down
before I unregister my servant.

> 
> Graham
Fred



-- 
Estelle et Philippe sont en voiture, Philippe conduit.
Ils s'observent discrètement de temps en temps l'air de rien.

Philippe (à part soi)
Cette chose céleste et seule. c'est Estelle !
Estelle (à part soi)
Il est beau, le pirate. Il a pris la bretelle.
Philippe (en plein fantasmes)
Elle, telle, couchée. Sous cette couette.. Chut !
Estelle (sensible à son charme)
Il a l'art et l'allure, il attire. Et le but ?
Philippe (se posant des questions graves)
Est-elle usuel test ou est-elle. l'Elue ?
Estelle (se posant les mêmes questions graves)
Peut-il être habituel ? Il te plait, il te tue..
Philippe (en plein coup de foudre)
Tu es touché, l'esthète. Oh, secousse ! Elle t'est.
Estelle (en plein fantasmes)
Ah brûler, haleter, le palper, palpiter.
Le Chœur
Accélère chéri cours au bout de la piste
Pour épuiser la lettre et chercher l'Oulipo
Cours épouser Estelle à l'autel du repos
L'alphabet peut créer et le couple et la liste

		-- Chamontin, Élisabeth


More information about the PolyORB-users mailing list