I was hoping to avoid introducing another dependency with memcached, but
I'll consider it.

I guess my question should be more pointed. The test case seems to evaluate
basic functionality, which appears not to work. Have others experienced this
bug (on mac os)? Or is it likely that this is a configuration dependent bug?
Has this been addressed in the git version of bdrb? Is a stable version of
bdrb that works on mac os forthcoming?

-pbaker

On 7/31/08, hemant <[EMAIL PROTECTED]> wrote:
>
> On Thu, Jul 31, 2008 at 1:52 PM, hemant <[EMAIL PROTECTED]> wrote:
> > On Thu, Jul 31, 2008 at 10:53 AM, P Baker <[EMAIL PROTECTED]> wrote:
> >> Hey all, fairly new to Rails and definitely new to BackgrounDRB, thanks
> for
> >> your hard work.
> >>
> >> However, I'm curious about incompatibilities between the latest stable
> >> release of bdrb (from the svn mirror) and mac os x. I've got (nearly)
> >> identical setups on a Debian Etch and Mac OS X 10.5.3 system running
> rails
> >> 2.1.0, ruby 1.8.6 (2008-03-03 patchlevel 114), latest stable versions of
> >> packet and chronic. The attached (mirrored at
> >> http://www.sendspace.com/file/ulw9o2) rails project, which has a simple
> demo
> >> ProgressWorker, demonstrates my concerns.
> >>
> >> Running ./script/backgroundrb, and then in the console typing
> >> MiddleMan.worker(:progress_worker).ask_result(:worker) produces
> different
> >> results. On the debian system it produces the expected result, while mac
> >> reports:
> >>
> >> NoMethodError: You have a nil object when you didn't expect it!
> >> You might have expected an instance of ActiveRecord::Base.
> >> The error occurred while evaluating nil.[]
> >>
> >>
> from.../vendor/plugins/backgroundrb/lib/backgroundrb/bdrb_connection.rb:151:in
> >> `ask_result'
> >>     from
> >>
> .../vendor/plugins/backgroundrb/lib/backgroundrb/rails_worker_proxy.rb:78:in
> >> `ask_result'
> >>     from
> >>
> .../vendor/plugins/backgroundrb/lib/backgroundrb/rails_worker_proxy.rb:78:in
> >> `map'
> >>     from
> >>
> .../vendor/plugins/backgroundrb/lib/backgroundrb/rails_worker_proxy.rb:78:in
> >> `ask_result'
> >>     from (irb):1
> >>
> >> Has anyone else experienced this? Is this a known bug? Are there other
> >> differences in threading between OSs? I develop on a mac and the
> production
> >> server is Debian, so I'm curious as to what to expect...Any guidance
> would
> >> be appreciated.
> >>
> >
> > Well, there are some issues if you are dynamically starting workers
> > using MiddleMan.new_worker on OSX, but your code should work without
> > any problems on OSX.
>
>
> Also, use memcache for result storage, configuration is rather simple:
>
> http://backgroundrb.rubyforge.org/workers/
>
> It will give you much better stability and results.
>
_______________________________________________
Backgroundrb-devel mailing list
[email protected]
http://rubyforge.org/mailman/listinfo/backgroundrb-devel

Reply via email to