Derek Doda
2006-Nov-29 17:28 UTC
[Backgroundrb-devel] Noob needs help installing backgroundrb on Windows XP
Hey Guys, In the readme for Backgroundrb it says that windows support has been depcreated for this version, but then it goes on to mention how to use it in Windows. So I''m not sure if it should be running on windows or not, so I''ll ask anyway. Also, I''m new to ruby and I''m also new to server administration, so I apologize if my questions are pretty simple. I''ve tried to install backgroundrb on windows by doing the following: Installed slave 1.0.0 by using ''gem install slave'' which seemed to work Installed daemons 1.0.3. by using ''gem install daemons'' which also seemed to work I downloaded backgroundrb via SVN into the vendor/plugin/backgroundrb vendor plugin. Did a ''rake backgroundrb:setup'' When I try to view a page it only renders "<h2>Application error</h2>Rails application failed to start properly". These are the errors that I got from Apache 2.2 Premature end of script headers: dispatch.cgi C:/ruby/lib/ruby/1.8/pathname.rb:341:in `lstat'': Invalid argument - /C:/work/websites/cms/build1/cms/public/C:/work/websites/cms/build1/cms/public/../config (Errno::EINVAL)\r \tfrom C:/ruby/lib/ruby/1.8/pathname.rb:341:in `realpath''\r \tfrom C:/work/websites/cms/build1/cms/public/../config/../vendor/plugins/backgroundrb/lib/middleman_rails_init.rb:2\r \tfrom C:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in `require''\r \tfrom C:/ruby/lib/ruby/gems/1.8/gems/activesupport-1.3.1/lib/active_support/dependencies.rb:147:in `require''\r \tfrom C:/work/websites/cms/build1/cms/public/../config/../vendor/plugins/backgroundrb/init.rb:2:in `load_plugin''\r \tfrom C:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/initializer.rb:348:in `load_plugin''\r \tfrom C:/ruby/lib/ruby/gems/1.8/gems/activesupport-1.3.1/lib/active_support/core_ext/kernel/reporting.rb:11:in `silence_warnings''\r \tfrom C:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/initializer.rb:348:in `load_plugin''\r \tfrom C:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/initializer.rb:158:in `load_plugins''\r \tfrom C:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/initializer.rb:158:in `load_plugins''\r \tfrom C:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/initializer.rb:102:in `process''\r \tfrom C:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/initializer.rb:42:in `run''\r \tfrom C:/work/websites/cms/build1/cms/public/../config/environment.rb:13\r \tfrom C:/work/websites/cms/build1/cms/public/dispatch.cgi:3\r Any help would be appreciated Cheers, -Derek
Ezra Zygmuntowicz
2006-Nov-29 20:04 UTC
[Backgroundrb-devel] Noob needs help installing backgroundrb on Windows XP
Hey Derek- Yeah the new version does not currently work on windows because slave does a lot of fork''ing which doesn''t work seamlessly on windows. There is talk of working towards a windows version of slave that would allow backgroundrb 0.2.x to work on windows. But for now your options on windows is to use the new bdrb under cygwin, or use the older version of the plugin from the svn at rubyforge. That version still works fine and will work on windows. Cheers- -Ezra On Nov 29, 2006, at 9:28 AM, Derek Doda wrote:> Hey Guys, > > In the readme for Backgroundrb it says that windows support has been > depcreated for this version, but then it goes on to mention how to use > it in Windows. So I''m not sure if it should be running on windows or > not, so I''ll ask anyway. Also, I''m new to ruby and I''m also new to > server administration, so I apologize if my questions are pretty > simple. > > I''ve tried to install backgroundrb on windows by doing the following: > > Installed slave 1.0.0 by using ''gem install slave'' which seemed to > work > Installed daemons 1.0.3. by using ''gem install daemons'' which also > seemed to work > > I downloaded backgroundrb via SVN into the vendor/plugin/backgroundrb > vendor plugin. > Did a ''rake backgroundrb:setup'' > > When I try to view a page it only renders "<h2>Application > error</h2>Rails application failed to start properly". > > These are the errors that I got from Apache 2.2 > > Premature end of script headers: dispatch.cgi > C:/ruby/lib/ruby/1.8/pathname.rb:341:in `lstat'': Invalid argument - > /C:/work/websites/cms/build1/cms/public/C:/work/websites/cms/build1/ > cms/public/../config > (Errno::EINVAL)\r > \tfrom C:/ruby/lib/ruby/1.8/pathname.rb:341:in `realpath''\r > \tfrom > C:/work/websites/cms/build1/cms/public/../config/../vendor/plugins/ > backgroundrb/lib/middleman_rails_init.rb:2\r > \tfrom C:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb: > 27:in > `require''\r > \tfrom > C:/ruby/lib/ruby/gems/1.8/gems/activesupport-1.3.1/lib/ > active_support/dependencies.rb:147:in > `require''\r > \tfrom > C:/work/websites/cms/build1/cms/public/../config/../vendor/plugins/ > backgroundrb/init.rb:2:in > `load_plugin''\r > \tfrom > C:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/initializer.rb:348:in > `load_plugin''\r > \tfrom > C:/ruby/lib/ruby/gems/1.8/gems/activesupport-1.3.1/lib/ > active_support/core_ext/kernel/reporting.rb:11:in > `silence_warnings''\r > \tfrom > C:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/initializer.rb:348:in > `load_plugin''\r > \tfrom > C:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/initializer.rb:158:in > `load_plugins''\r > \tfrom > C:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/initializer.rb:158:in > `load_plugins''\r > \tfrom > C:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/initializer.rb:102:in > `process''\r > \tfrom > C:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/initializer.rb:42:in > `run''\r > \tfrom C:/work/websites/cms/build1/cms/public/../config/ > environment.rb:13\r > \tfrom C:/work/websites/cms/build1/cms/public/dispatch.cgi:3\r > > Any help would be appreciated > > Cheers, > -Derek > > _______________________________________________ > Backgroundrb-devel mailing list > Backgroundrb-devel at rubyforge.org > http://rubyforge.org/mailman/listinfo/backgroundrb-devel >-- Ezra Zygmuntowicz -- Lead Rails Evangelist -- ez at engineyard.com -- Engine Yard, Serious Rails Hosting -- (866) 518-YARD (9273)
Michael Siebert
2006-Nov-29 20:49 UTC
[Backgroundrb-devel] Noob needs help installing backgroundrb on Windows XP
Hey y''all, if its only about fork''ing, there is a gem on rubyforge that does exactly that: provide fork on windows. http://rubyforge.org/projects/win32utils/ win32-process should do the trick. if you search the ml archives, you''ll find a post by me about using backgroundrb in daemon mode on win32 (some time ago where bgdrb used fork for daemoning). unfortunately everyone ignored that post. hopefully you don''t ignore that one again, since it worked wonderful when i tried it. dont know about slave, but i think win32-utils can help out a bit there. beware: i didnt test that trickt because a. im using sonme older thread-pool-version and b. hardly switch my windows pc on since i have my macbook :) solong... Micha Am 29.11.2006 um 21:04 schrieb Ezra Zygmuntowicz:> Hey Derek- > > Yeah the new version does not currently work on windows because > slave does a lot of fork''ing which doesn''t work seamlessly on > windows. There is talk of working towards a windows version of slave > that would allow backgroundrb 0.2.x to work on windows. But for now > your options on windows is to use the new bdrb under cygwin, or use > the older version of the plugin from the svn at rubyforge. That > version still works fine and will work on windows. > > > Cheers- > > -Ezra > > On Nov 29, 2006, at 9:28 AM, Derek Doda wrote: > >> Hey Guys, >> >> In the readme for Backgroundrb it says that windows support has been >> depcreated for this version, but then it goes on to mention how to >> use >> it in Windows. So I''m not sure if it should be running on windows or >> not, so I''ll ask anyway. Also, I''m new to ruby and I''m also new to >> server administration, so I apologize if my questions are pretty >> simple. >> >> I''ve tried to install backgroundrb on windows by doing the following: >> >> Installed slave 1.0.0 by using ''gem install slave'' which seemed to >> work >> Installed daemons 1.0.3. by using ''gem install daemons'' which also >> seemed to work >> >> I downloaded backgroundrb via SVN into the vendor/plugin/backgroundrb >> vendor plugin. >> Did a ''rake backgroundrb:setup'' >> >> When I try to view a page it only renders "<h2>Application >> error</h2>Rails application failed to start properly". >> >> These are the errors that I got from Apache 2.2 >> >> Premature end of script headers: dispatch.cgi >> C:/ruby/lib/ruby/1.8/pathname.rb:341:in `lstat'': Invalid argument - >> /C:/work/websites/cms/build1/cms/public/C:/work/websites/cms/build1/ >> cms/public/../config >> (Errno::EINVAL)\r >> \tfrom C:/ruby/lib/ruby/1.8/pathname.rb:341:in `realpath''\r >> \tfrom >> C:/work/websites/cms/build1/cms/public/../config/../vendor/plugins/ >> backgroundrb/lib/middleman_rails_init.rb:2\r >> \tfrom C:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb: >> 27:in >> `require''\r >> \tfrom >> C:/ruby/lib/ruby/gems/1.8/gems/activesupport-1.3.1/lib/ >> active_support/dependencies.rb:147:in >> `require''\r >> \tfrom >> C:/work/websites/cms/build1/cms/public/../config/../vendor/plugins/ >> backgroundrb/init.rb:2:in >> `load_plugin''\r >> \tfrom >> C:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/initializer.rb:348:in >> `load_plugin''\r >> \tfrom >> C:/ruby/lib/ruby/gems/1.8/gems/activesupport-1.3.1/lib/ >> active_support/core_ext/kernel/reporting.rb:11:in >> `silence_warnings''\r >> \tfrom >> C:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/initializer.rb:348:in >> `load_plugin''\r >> \tfrom >> C:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/initializer.rb:158:in >> `load_plugins''\r >> \tfrom >> C:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/initializer.rb:158:in >> `load_plugins''\r >> \tfrom >> C:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/initializer.rb:102:in >> `process''\r >> \tfrom >> C:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/initializer.rb:42:in >> `run''\r >> \tfrom C:/work/websites/cms/build1/cms/public/../config/ >> environment.rb:13\r >> \tfrom C:/work/websites/cms/build1/cms/public/dispatch.cgi:3\r >> >> Any help would be appreciated >> >> Cheers, >> -Derek >> >> _______________________________________________ >> Backgroundrb-devel mailing list >> Backgroundrb-devel at rubyforge.org >> http://rubyforge.org/mailman/listinfo/backgroundrb-devel >> > > -- Ezra Zygmuntowicz > -- Lead Rails Evangelist > -- ez at engineyard.com > -- Engine Yard, Serious Rails Hosting > -- (866) 518-YARD (9273) > > > _______________________________________________ > Backgroundrb-devel mailing list > Backgroundrb-devel at rubyforge.org > http://rubyforge.org/mailman/listinfo/backgroundrb-devel----------------------------- Siebert Michael info at siebert-wd.de --- ACHTUNG potenzieller Amokl?ufer: spiele Killerspiele (Scarface, GTA, UT) schaue Horrorfilme (Wrong Turn, Texas Chainsaw Massacre) h?re Musik von Anarchisten und Dunklen (Rammstein, Tote Hosen, Wizo) h?re Nazi-Musik von den B?hsen Onkelz, bin also auch noch Neonazi war mal auf ner Antifa-Demo war beim B.U.N.D. ich mag Ironie
Ezra Zygmuntowicz
2006-Nov-29 21:19 UTC
[Backgroundrb-devel] Noob needs help installing backgroundrb on Windows XP
Unfortunately that won''t cut it in this case, I wish it would. Slave does more then just fork. It uses ipc and a few other things that just don''t work yet on windows. There is a possibility it could be made to work but right now it does not, even with win32 process. -Ezra On Nov 29, 2006, at 12:49 PM, Michael Siebert wrote:> Hey y''all, > if its only about fork''ing, there is a gem on rubyforge that does > exactly that: provide fork on windows. > > http://rubyforge.org/projects/win32utils/ > > win32-process should do the trick. if you search the ml archives, > you''ll find a post by me about using backgroundrb in daemon mode on > win32 (some time ago where bgdrb used fork for daemoning). > unfortunately everyone ignored that post. hopefully you don''t > ignore that one again, since it worked wonderful when i tried it. > dont know about slave, but i think win32-utils can help out a bit > there. > beware: i didnt test that trickt because a. im using sonme older > thread-pool-version and b. hardly switch my windows pc on since i > have my macbook :) > > solong... > Micha > > Am 29.11.2006 um 21:04 schrieb Ezra Zygmuntowicz: > >> Hey Derek- >> >> Yeah the new version does not currently work on windows because >> slave does a lot of fork''ing which doesn''t work seamlessly on >> windows. There is talk of working towards a windows version of slave >> that would allow backgroundrb 0.2.x to work on windows. But for now >> your options on windows is to use the new bdrb under cygwin, or use >> the older version of the plugin from the svn at rubyforge. That >> version still works fine and will work on windows. >> >> >> Cheers- >> >> -Ezra >> >> On Nov 29, 2006, at 9:28 AM, Derek Doda wrote: >> >>> Hey Guys, >>> >>> In the readme for Backgroundrb it says that windows support has been >>> depcreated for this version, but then it goes on to mention how >>> to use >>> it in Windows. So I''m not sure if it should be running on >>> windows or >>> not, so I''ll ask anyway. Also, I''m new to ruby and I''m also new to >>> server administration, so I apologize if my questions are pretty >>> simple. >>> >>> I''ve tried to install backgroundrb on windows by doing the >>> following: >>> >>> Installed slave 1.0.0 by using ''gem install slave'' which seemed to >>> work >>> Installed daemons 1.0.3. by using ''gem install daemons'' which also >>> seemed to work >>> >>> I downloaded backgroundrb via SVN into the vendor/plugin/ >>> backgroundrb >>> vendor plugin. >>> Did a ''rake backgroundrb:setup'' >>> >>> When I try to view a page it only renders "<h2>Application >>> error</h2>Rails application failed to start properly". >>> >>> These are the errors that I got from Apache 2.2 >>> >>> Premature end of script headers: dispatch.cgi >>> C:/ruby/lib/ruby/1.8/pathname.rb:341:in `lstat'': Invalid argument - >>> /C:/work/websites/cms/build1/cms/public/C:/work/websites/cms/build1/ >>> cms/public/../config >>> (Errno::EINVAL)\r >>> \tfrom C:/ruby/lib/ruby/1.8/pathname.rb:341:in `realpath''\r >>> \tfrom >>> C:/work/websites/cms/build1/cms/public/../config/../vendor/plugins/ >>> backgroundrb/lib/middleman_rails_init.rb:2\r >>> \tfrom C:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb: >>> 27:in >>> `require''\r >>> \tfrom >>> C:/ruby/lib/ruby/gems/1.8/gems/activesupport-1.3.1/lib/ >>> active_support/dependencies.rb:147:in >>> `require''\r >>> \tfrom >>> C:/work/websites/cms/build1/cms/public/../config/../vendor/plugins/ >>> backgroundrb/init.rb:2:in >>> `load_plugin''\r >>> \tfrom >>> C:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/initializer.rb:348:in >>> `load_plugin''\r >>> \tfrom >>> C:/ruby/lib/ruby/gems/1.8/gems/activesupport-1.3.1/lib/ >>> active_support/core_ext/kernel/reporting.rb:11:in >>> `silence_warnings''\r >>> \tfrom >>> C:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/initializer.rb:348:in >>> `load_plugin''\r >>> \tfrom >>> C:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/initializer.rb:158:in >>> `load_plugins''\r >>> \tfrom >>> C:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/initializer.rb:158:in >>> `load_plugins''\r >>> \tfrom >>> C:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/initializer.rb:102:in >>> `process''\r >>> \tfrom >>> C:/ruby/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/initializer.rb:42:in >>> `run''\r >>> \tfrom C:/work/websites/cms/build1/cms/public/../config/ >>> environment.rb:13\r >>> \tfrom C:/work/websites/cms/build1/cms/public/dispatch.cgi:3\r >>> >>> Any help would be appreciated >>> >>> Cheers, >>> -Derek >>> >>> _______________________________________________ >>> Backgroundrb-devel mailing list >>> Backgroundrb-devel at rubyforge.org >>> http://rubyforge.org/mailman/listinfo/backgroundrb-devel >>> >> >> -- Ezra Zygmuntowicz-- Lead Rails Evangelist >> -- ez at engineyard.com >> -- Engine Yard, Serious Rails Hosting >> -- (866) 518-YARD (9273) >> >> >> _______________________________________________ >> Backgroundrb-devel mailing list >> Backgroundrb-devel at rubyforge.org >> http://rubyforge.org/mailman/listinfo/backgroundrb-devel > > ----------------------------- > Siebert Michael > info at siebert-wd.de > > --- > > ACHTUNG potenzieller Amokl?ufer: > spiele Killerspiele (Scarface, GTA, UT) > schaue Horrorfilme (Wrong Turn, Texas Chainsaw Massacre) > h?re Musik von Anarchisten und Dunklen (Rammstein, Tote Hosen, Wizo) > h?re Nazi-Musik von den B?hsen Onkelz, bin also auch noch Neonazi > war mal auf ner Antifa-Demo > war beim B.U.N.D. > ich mag Ironie > > > >-- Ezra Zygmuntowicz -- Lead Rails Evangelist -- ez at engineyard.com -- Engine Yard, Serious Rails Hosting -- (866) 518-YARD (9273)
Chris H
2006-Dec-01 02:51 UTC
[Backgroundrb-devel] Noob needs help installing backgroundrb on Windows XP
Hi, I''ve just installed background rb 0.2.1. When I try start a worker in my application controller I receive the following error: wrong number of arguments (2 for 1) - (ArgumentError) /home/chris/projects/call_manager/trunk/call_manager_app/vendor/plugins/backgroundrb/server/lib/backgroundrb/middleman.rb:211:in `initialize'' /home/chris/projects/call_manager/trunk/call_manager_app/vendor/plugins/backgroundrb/server/lib/backgroundrb/middleman.rb:211:in `new_worker'' /home/chris/projects/call_manager/trunk/call_manager_app/vendor/plugins/backgroundrb/server/lib/backgroundrb/thread_pool.rb:36:in `dispatch'' /home/chris/projects/call_manager/trunk/call_manager_app/vendor/plugins/backgroundrb/server/lib/backgroundrb/thread_pool.rb:22:in `dispatch'' /home/chris/projects/call_manager/trunk/call_manager_app/vendor/plugins/backgroundrb/server/lib/backgroundrb/middleman.rb:199:in `new_worker'' /usr/local/lib/ruby/1.8/drb/drb.rb:1552:in `perform_without_block'' /usr/local/lib/ruby/1.8/drb/drb.rb:1512:in `perform'' /usr/local/lib/ruby/1.8/drb/drb.rb:1586:in `main_loop'' /usr/local/lib/ruby/1.8/drb/drb.rb:1582:in `main_loop'' /usr/local/lib/ruby/1.8/drb/drb.rb:1578:in `main_loop'' /usr/local/lib/ruby/1.8/drb/drb.rb:1427:in `run'' /usr/local/lib/ruby/1.8/drb/drb.rb:1424:in `run'' /usr/local/lib/ruby/1.8/drb/drb.rb:1344:in `initialize'' /usr/local/lib/ruby/1.8/drb/drb.rb:1624:in `start_service'' /home/chris/projects/call_manager/trunk/call_manager_app/vendor/plugins/backgroundrb/server/lib/backgroundrb_server.rb:315:in `run'' /usr/local/lib/ruby/gems/1.8/gems/daemons-1.0.3/lib/daemons/application.rb:186:in `start_proc'' /usr/local/lib/ruby/gems/1.8/gems/daemons-1.0.3/lib/daemons/application.rb:196:in `start_proc'' /usr/local/lib/ruby/gems/1.8/gems/daemons-1.0.3/lib/daemons/application.rb:226:in `start'' /usr/local/lib/ruby/gems/1.8/gems/daemons-1.0.3/lib/daemons/controller.rb:72:in `run'' /usr/local/lib/ruby/gems/1.8/gems/daemons-1.0.3/lib/daemons.rb:179:in `run_proc'' /usr/local/lib/ruby/gems/1.8/gems/daemons-1.0.3/lib/daemons/cmdline.rb:94:in `catch_exceptions'' /usr/local/lib/ruby/gems/1.8/gems/daemons-1.0.3/lib/daemons.rb:178:in `run_proc'' /home/chris/projects/call_manager/trunk/call_manager_app/vendor/plugins/backgroundrb/server/lib/backgroundrb_server.rb:301:in `run'' I''m running slave (1.1.0) and daemons (1.0.3) as required. I''m starting the worker with: MiddleMan.new_worker(:class => :calls_worker, :job_key => :calls_watcher) thanks in advance! cheers, chris.
skaar
2006-Dec-01 03:40 UTC
[Backgroundrb-devel] Noob needs help installing backgroundrb on Windows XP
hmm, do you have your own initialize in your worker class? can you give us a skeleton of your worker class? /skaar * Chris H (chris at etechdata.com.au) [061130 21:38]:> Hi, > > I''ve just installed background rb 0.2.1. > > When I try start a worker in my application controller I receive the > following error: > > > wrong number of arguments (2 for 1) - (ArgumentError) > /home/chris/projects/call_manager/trunk/call_manager_app/vendor/plugins/backgroundrb/server/lib/backgroundrb/middleman.rb:211:in > `initialize'' > /home/chris/projects/call_manager/trunk/call_manager_app/vendor/plugins/backgroundrb/server/lib/backgroundrb/middleman.rb:211:in > `new_worker'' > /home/chris/projects/call_manager/trunk/call_manager_app/vendor/plugins/backgroundrb/server/lib/backgroundrb/thread_pool.rb:36:in > `dispatch'' > /home/chris/projects/call_manager/trunk/call_manager_app/vendor/plugins/backgroundrb/server/lib/backgroundrb/thread_pool.rb:22:in > `dispatch'' > /home/chris/projects/call_manager/trunk/call_manager_app/vendor/plugins/backgroundrb/server/lib/backgroundrb/middleman.rb:199:in > `new_worker'' > /usr/local/lib/ruby/1.8/drb/drb.rb:1552:in `perform_without_block'' > /usr/local/lib/ruby/1.8/drb/drb.rb:1512:in `perform'' > /usr/local/lib/ruby/1.8/drb/drb.rb:1586:in `main_loop'' > /usr/local/lib/ruby/1.8/drb/drb.rb:1582:in `main_loop'' > /usr/local/lib/ruby/1.8/drb/drb.rb:1578:in `main_loop'' > /usr/local/lib/ruby/1.8/drb/drb.rb:1427:in `run'' > /usr/local/lib/ruby/1.8/drb/drb.rb:1424:in `run'' > /usr/local/lib/ruby/1.8/drb/drb.rb:1344:in `initialize'' > /usr/local/lib/ruby/1.8/drb/drb.rb:1624:in `start_service'' > /home/chris/projects/call_manager/trunk/call_manager_app/vendor/plugins/backgroundrb/server/lib/backgroundrb_server.rb:315:in > `run'' > /usr/local/lib/ruby/gems/1.8/gems/daemons-1.0.3/lib/daemons/application.rb:186:in > `start_proc'' > /usr/local/lib/ruby/gems/1.8/gems/daemons-1.0.3/lib/daemons/application.rb:196:in > `start_proc'' > /usr/local/lib/ruby/gems/1.8/gems/daemons-1.0.3/lib/daemons/application.rb:226:in > `start'' > /usr/local/lib/ruby/gems/1.8/gems/daemons-1.0.3/lib/daemons/controller.rb:72:in > `run'' > /usr/local/lib/ruby/gems/1.8/gems/daemons-1.0.3/lib/daemons.rb:179:in > `run_proc'' > /usr/local/lib/ruby/gems/1.8/gems/daemons-1.0.3/lib/daemons/cmdline.rb:94:in > `catch_exceptions'' > /usr/local/lib/ruby/gems/1.8/gems/daemons-1.0.3/lib/daemons.rb:178:in > `run_proc'' > /home/chris/projects/call_manager/trunk/call_manager_app/vendor/plugins/backgroundrb/server/lib/backgroundrb_server.rb:301:in > `run'' > > > I''m running slave (1.1.0) and daemons (1.0.3) as required. > > I''m starting the worker with: > MiddleMan.new_worker(:class => :calls_worker, :job_key => :calls_watcher) > > thanks in advance! > > cheers, > chris. > > > _______________________________________________ > 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 ----------------------------------------------------------------------
Chris H
2006-Dec-01 04:07 UTC
[Backgroundrb-devel] Noob needs help installing backgroundrb on Windows XP
I removed my initialize method and it''s working as expected :) this is what I had: def initialize(args) @running = true super(args) end def do_work(args) # This method is called in it''s own new thread when you # call new worker. args is set to :args while @running #code went here end end now I''ved moved @running = true into do_work. How come I wasn''t able to do what I did with initialize? Cheers, chris.>hmm, do you have your own initialize in your worker class? can you give >us a skeleton of your worker class? > >/skaar > > >* Chris H (chris at etechdata.com.au) [061130 21:38]: > > >>Hi, >> >>I''ve just installed background rb 0.2.1. >> >>When I try start a worker in my application controller I receive the >>following error: >> >> >>wrong number of arguments (2 for 1) - (ArgumentError) >>/home/chris/projects/call_manager/trunk/call_manager_app/vendor/plugins/backgroundrb/server/lib/backgroundrb/middleman.rb:211:in >>`initialize'' >>/home/chris/projects/call_manager/trunk/call_manager_app/vendor/plugins/backgroundrb/server/lib/backgroundrb/middleman.rb:211:in >>`new_worker'' >>/home/chris/projects/call_manager/trunk/call_manager_app/vendor/plugins/backgroundrb/server/lib/backgroundrb/thread_pool.rb:36:in >>`dispatch'' >>/home/chris/projects/call_manager/trunk/call_manager_app/vendor/plugins/backgroundrb/server/lib/backgroundrb/thread_pool.rb:22:in >>`dispatch'' >>/home/chris/projects/call_manager/trunk/call_manager_app/vendor/plugins/backgroundrb/server/lib/backgroundrb/middleman.rb:199:in >>`new_worker'' >>/usr/local/lib/ruby/1.8/drb/drb.rb:1552:in `perform_without_block'' >>/usr/local/lib/ruby/1.8/drb/drb.rb:1512:in `perform'' >>/usr/local/lib/ruby/1.8/drb/drb.rb:1586:in `main_loop'' >>/usr/local/lib/ruby/1.8/drb/drb.rb:1582:in `main_loop'' >>/usr/local/lib/ruby/1.8/drb/drb.rb:1578:in `main_loop'' >>/usr/local/lib/ruby/1.8/drb/drb.rb:1427:in `run'' >>/usr/local/lib/ruby/1.8/drb/drb.rb:1424:in `run'' >>/usr/local/lib/ruby/1.8/drb/drb.rb:1344:in `initialize'' >>/usr/local/lib/ruby/1.8/drb/drb.rb:1624:in `start_service'' >>/home/chris/projects/call_manager/trunk/call_manager_app/vendor/plugins/backgroundrb/server/lib/backgroundrb_server.rb:315:in >>`run'' >>/usr/local/lib/ruby/gems/1.8/gems/daemons-1.0.3/lib/daemons/application.rb:186:in >>`start_proc'' >>/usr/local/lib/ruby/gems/1.8/gems/daemons-1.0.3/lib/daemons/application.rb:196:in >>`start_proc'' >>/usr/local/lib/ruby/gems/1.8/gems/daemons-1.0.3/lib/daemons/application.rb:226:in >>`start'' >>/usr/local/lib/ruby/gems/1.8/gems/daemons-1.0.3/lib/daemons/controller.rb:72:in >>`run'' >>/usr/local/lib/ruby/gems/1.8/gems/daemons-1.0.3/lib/daemons.rb:179:in >>`run_proc'' >>/usr/local/lib/ruby/gems/1.8/gems/daemons-1.0.3/lib/daemons/cmdline.rb:94:in >>`catch_exceptions'' >>/usr/local/lib/ruby/gems/1.8/gems/daemons-1.0.3/lib/daemons.rb:178:in >>`run_proc'' >>/home/chris/projects/call_manager/trunk/call_manager_app/vendor/plugins/backgroundrb/server/lib/backgroundrb_server.rb:301:in >>`run'' >> >> >>I''m running slave (1.1.0) and daemons (1.0.3) as required. >> >>I''m starting the worker with: >>MiddleMan.new_worker(:class => :calls_worker, :job_key => :calls_watcher) >> >>thanks in advance! >> >>cheers, >>chris. >> >> >>_______________________________________________ >>Backgroundrb-devel mailing list >>Backgroundrb-devel at rubyforge.org >>http://rubyforge.org/mailman/listinfo/backgroundrb-devel >> >> > > >