Stopping a specific DRb service

C

Christopher Dancy

I have a DRb service which in turn spawns off multiple threads. Each of
these threads interacts with other DRb services on different machines.
To interact with these other DRb services I of course do something to
the effect of

DRb.start_service
status = DRbObject.new_with_uri(blah blah blah)

So far I've just let the method finish which calls these external DRb
services. However this does not close the connection with them. The
method itself finishes but the connection is still live. If I attempt to
do DRb.stop_service it kills the main program altogether. Is there a way
I can close that specific connection with killing the main executing
program?
 
C

Christopher Dancy

Christopher said:
I have a DRb service which in turn spawns off multiple threads. Each of
these threads interacts with other DRb services on different machines.
To interact with these other DRb services I of course do something to
the effect of

DRb.start_service
status = DRbObject.new_with_uri(blah blah blah)

So far I've just let the method finish which calls these external DRb
services. However this does not close the connection with them. The
method itself finishes but the connection is still live. If I attempt to
do DRb.stop_service it kills the main program altogether. Is there a way
I can close that specific connection with killing the main executing
program?

SOLVED. I was under the impression ( not sure which site at the moment
gave me the idea ) that in order to communicate with a DRb service the
calling thread had to do something like "DRb.start_service" for just
issuing a command. If I had read the actual DRbServer Documentation
earlier I might have avoided this problem. Requiring 'drb' and doing
something like "status = DRbObject.new_with_uri(host:port).get_status"
worked just fine. Just an FYI in case anyone comes across this same
problem.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,482
Members
44,901
Latest member
Noble71S45

Latest Threads

Top