[Backgroundrb-devel] ncluding backgroundrb issue

skaar skaar at waste.org
Wed Feb 7 06:18:06 EST 2007


I'm not quite sure what you are trying to do here - are you trying to
require a file with a BackgrounDRb worker class in your Rails
controller? In that case - that's just not how it works. The BackgrouDRb
worker classes need the backgroundrb server process. Take a look at the
documentation again.

/skaar


* Gabi Ciudoiu (ciudica at gmail.com) [070207 03:59]:
>  I have the next including files structure :
> 
>      - controller fileaA.rb including line (#8): require "fileB"...
>      - /lib/fileB.rb with main header: load 'backgroundrb/worker.rb'
>                                                   load 'backgroundrb/
>  worker_rails.rb'
>                                                    class FileB <
>  BackgrounDRb::Worker::RailsBase
>                                                    ........................................................................
>                               and on line #72:  FileB .register
>  when I restart my lighttpd web server , at the first loading of the
>  controller it rise the next error:
> 
>  You have a nil object when you didn't expect it!
>  You might have expected an instance of Array.
> 
>  The error occured while evaluating nil.include?
> 
>  RAILS_ROOT: ......
>  Application Trace | Framework Trace | Full Trace
> 
>  #{RAILS_ROOT}/vendor/plugins/backgroundrb/server/lib/backgroundrb
>  /
>  middleman.rb:158:in `register_worker_class'
>  #{RAILS_ROOT}/vendor/plugins/backgroundrb/server/lib/backgroundrb
>  /
>  worker.rb:17:in `register'
>  #{RAILS_ROOT}/lib/fileB.rb:72
>  #{RAILS_ROOT}/app/controllers/fileA.rb:8
> 
>  After reloading the page, this error did not rise again , I need help
>  with any idea concerning this behavior of backgroundrb plugin (what is
>  wrong in my including code or what could generate this error?)
> 
>  Thank's

> _______________________________________________
> Backgroundrb-devel mailing list
> Backgroundrb-devel at rubyforge.org
> http://rubyforge.org/mailman/listinfo/backgroundrb-devel

-- 
----------------------------------------------------------------------
|\|\             where in the       |          s_u_b_s_t_r_u_c_t_i_o_n 
| | >===========  W.A.S.T.E.        |                  genarratologies 
|/|/    (_)     is the wisdom       |                  skaar at waste.org
----------------------------------------------------------------------


More information about the Backgroundrb-devel mailing list