[Backgroundrb-devel] Get "some read error" on calls to worker

Rob Nielsen rob at iotum.com
Mon Dec 17 15:18:34 EST 2007

-----Original Message-----
From: hemant kumar [mailto:gethemant at gmail.com] 
Sent: Monday, December 17, 2007 3:09 PM
To: Rob Nielsen
Cc: backgroundrb-devel
Subject: RE: [Backgroundrb-devel] Get "some read error" on calls to

> 2. Does ask_status throw an exception if the worker isn't running? I
> would like to be able to ask if the worker is running before starting
> another one.

Nope, It won't throw any exception in user code. It does throw an
exception internally. However, you can query status of all workers that
are currently running, using 


See, if that output is helpful.

I do get an exception: BackgrounDRb::BdrbConnError when I do the
following and the worker is not running.

worker_status = MiddleMan.ask_status(:worker =>
:update_facebook_account_info_worker, :job_key => @id)

I don't mind using a begin rescue block if that is the way to verify
that the worker is not running. Is there a better way?

P.S. I'm on IRC now but no one seems to be answering (I'm an IRC noob -

Let them talk of their oriental summer climes of everlasting
conservatories; give me the privilege of making my own summer with my
own coals.


More information about the Backgroundrb-devel mailing list