On Apr 29, 2007, at 4:17 AM, Farrel Lifson wrote:

> Hi all,
>
> I'm busy experimenting with DRb and I've hit some strange behaviour
> which I can't get seem to find the cause of. I think it might be
> something to do with DRb and forks but I'm unsure. The process I'm
> trying to achieve is to have a Server process running as a DRb
> service. It can spawn client processes (the create_client method)
> which also run using a DRb service.
>

> <snip>

> Any DRb experts out there who can help?
>
> Thanks
> Farrel
> <base.rb>
> <client.rb>
> <server.rb>


Hey Farrel-

	I'll save you a lot of hassle. Go grab the slave gem off rubyforge.  
It does exactly what you are trying to do. It allows you to fork  
child objects and it sets up a drb connection and a heartneat between  
the child and parent so if the parent dies, the children will also die.

http://codeforpeople.com/lib/ruby/slave/slave-1.2.1/README

Cheers-
-- Ezra Zygmuntowicz 
-- Lead Rails Evangelist
-- ez / engineyard.com
-- Engine Yard, Serious Rails Hosting
-- (866) 518-YARD (9273)