similar to: backgroundrb and rails environment in running tests

Displaying 20 results from an estimated 60000 matches similar to: "backgroundrb and rails environment in running tests"

2010 Jan 12
1
Rails after_initialize block doesn't seem to be run in the backgroundrb context
Hi all, Just had an interesting production failure while updating my Rails application - a bunch of code previously in config/environment.rb was put into config/initializers. That resulted in me having to wrap some code in config/environments/production.rb into an after_initialize do ... end block When backgroundrb was run against that code, the setup done in that after_initialize block
2008 Jun 14
0
does BackgrounDRB not "know" the rails environment it is running within/in parallel with?]
Hi, it probably is a noob question but I''m confused by this error message: active_support/dependencies.rb:478:in `const_missing'': uninitialized constant Invoice::ApplicationController Situation: I have an InvoicesController with a create method that in turn calls upon a MiddleMan.worker(:billing_worker), which in turn finds an Invoice and calls upon @invoice.print_invoice
2007 Jun 12
2
Starting script/ferret_start problems
Hi - I have a fresh install of OSX, Rails, Ruby, Ferret, AAF etc ... Everything is working fine, I can start mongrel, I can start backgroundrb, but Ferret Drb ... doesn''t want to work. RAILS_ENV=development script/ferret_start Gives me: env: script/runner: Permission denied Is there a way I can debug this to figure out what is going on - or is there another way to start Ferret Drb?
2007 May 04
1
Setting environment
> Chris T wrote: > > Not sure this is known behaviour but it seems that if want to set > the > > environment to, for example, test, and you want to use Active > Record you > > have to both explicitly set the RAILS_ENV and the BackgrounDRb > environment. > > I ran into essentially the same problem (needing to run BRB in the > test > environment so
2006 Oct 14
1
Setting environment
Not sure this is known behaviour but it seems that if want to set the environment to, for example, test, and you want to use Active Record you have to both explicitly set the RAILS_ENV and the BackgrounDRb environment. So, if you have a config file backgroundrb_test.yml (as well as the default) and set the environment to test in that, this is what *seems* to happen: $
2006 Dec 31
0
backgroundrb 0.2.1 doesn''t always load rails environment
I found this stack trace in my logs. My worker name is MiscWorker, and Qualifier is a Rails model. uninitialized constant MiscWorker::Qualifier: /Users/bryan/ Workspace/sandbox/scraper-trunk/config/../vendor/rails/activerecord/ lib/../../activesupport/lib/active_support/dependencies.rb:476:in `const_missing'' /Users/bryan/Workspace/sandbox/scraper-trunk/lib/workers/
2006 Nov 27
1
rails environment loaded but one plugin is undefined (using backgroundrb 0.2.0)
Hello all, I''m using BackgroundRb 0.2.0 (standalone) and in the do_work method of my worker, I''m working with objects from my Rails application. So in my config/backgroundrb.yml file, I added this line: :load_rails: true I think my worker isn''t doing what I want him to do. So I opened the console and read these error lines: # ruby script/backgroundrb console
2008 May 05
2
Deploying to a staging server using Capistrano: how to start up BackgrounDRb?
Hi. I am using BackgrounDRb to process thumbnails and upload to S3 - things are hunky-dory in development (thumbs are generated, these are uploaded to S3, the metadata is saved to trhe DB, and I get a nice status page updated by periodic calls via ask_status), but when I tried to deploy to our staging server and stop/start BackgrounDRb via Capistrano, things blew up - well, not exactly,
2006 Dec 14
0
feature request: config option to toggle scheduled jobs based on environment
I have BackgrounDRb configured to handle two cases of long-running tasks: (1) on-demand user triggered requests for some action, and (2) scheduled background running of tasks on a predetermined schedule. In my particular case, we have a publication task that can take several minutes to perform. Users can setup a regular publication schedule, or can hit a ''publish now'' button to
2008 Apr 11
3
does backgroundrb server need rails environment?
Hi everyone, I noticed that script/backgroudrb requires config/environment which causes the backgroundrb server as well as the log worker to ''bloat'' to 35MB each. I am kind of sensitive to memory issues, so I patched the code and essentially moved the require of environment from script/backgroundrb to the meta_worker. Everything seems good and now both backgroundrb server and
2008 May 29
0
How to know the environment (development/test/production) inside a worker - FIXED
Hi Guys,Looks like I have to do this in backgroundrb.yml :backgroundrb: :ip: 0.0.0.0 :production: :backgroundrb: :port: 11008 # use port 11008 :environment: production That is, have an entry for "environment: production" under :production:, This seems to have fixed the issue. Regards Sarat On 5/29/08, Sarat Kongara <saratkongara at gmail.com> wrote: > >
2007 Feb 14
1
Scheduling in backgroundrb not working
Hi , How do i schedule a job that can send emails at intervals of time using backgroundrb and rails For testing When i hit the controller i''m able send the emails. but that is not i intend to do ..... I want to use backgroundrb and rails in which i''ll schedule a job for every 5 minutes/ 1 minute or so..... to send an email But when i write
2008 May 21
2
How to know the environment (development/test/production) inside a worker
Hi Guys,You can start backgroundRb in different environments using -e option. ./script/backgroundrb -e production I like to run a rake task from my worker - something like rake RAILS_ENV=proper_environment thinking_sphinx:start I am not sure how to figure out the environment with which the backgroundRb is started from inside a worker task. Any help is appreciated. Thanks for your time. Regards
2006 Apr 20
2
index_dir path
Hi, I am running several applications, and I need them to share their indexed data. So instead of putting my index in the default location of RAILS_ROOT/index/RAILS_ENV I want it to appear in RAILS_ROOT/../index/RAILS_ENV (ie in the parent directory of each of my root directories ... I have three apps working together) In the acts_as_ferret file, I have changed line 73 to: index_base =
2007 Mar 04
0
Did BackgrounDRb change my apps behavior?
I just installed BackgrounDRb the other day. It''s working great but after I deployed to production, I noticed a couple of strange things happening: 1) I have the following code in a lib module and after deploying, IS_PRODUCTION was set to false. I''m not sure why this started occurring and the only major change was the installation of BackgrounDRb and its dependencies. Could
2008 Oct 14
3
Server settings for BackgrounDRB?
I have backgroundrb working locally and everything''s fine. However, i can''t get it running on our server. I read a blog post by David Burger about backgroundrb (http://david-burger.blogspot.com/2008/04/backgroundrb-rails-notes.html#comment-form) and it says that you set up your backgroundrb.yml file with a different section for each environment you want to use. Mine looks like
2006 Jul 31
1
Starting backgroundrb from rails and restarting with rails
Hi, I have my rails sites tricked out with capistrano, and backgroundrb, so I can easily use the ant tasks, but I would like to be able to start and stop backgroundrb from within rails. I have a few reasons for this: 1. Using fastcgi, backgroundrb would start under the apache user and the same mod_security context as apache, instead of my developer account which has many more privileges. 2.
2007 Jan 29
1
rails_env configuration conflict...
I''ve found a conflict in the way the configuration file is handled, in particular effecting the setting of the ENV[''RAILS_ENV''] value. When I attempted to run a worker in production, it would run fine the first time - the second time would fail because it was trying to access the development database. I had created a ''backgroundrb_prodcution.yml'' file
2010 May 07
0
Simple way to detect from rails if backgroundrb server is running
Sometimes I forgot to start the backgroundrb server while developing. Requests are added to queue until I remember. Is there a simple way from rails to detect if the server is running and if necessary start it? Thanks, Don Mc
2008 May 23
0
Backgroundrb-devel Digest, Vol 24, Issue 7
Hi, all. Just wondering if anyone has tried using the Paperclip file upload plugin with Backgroundrb. My current implementation uses attachment_fu - I save the file initially to the file system without generating thumbs, then a bdrb process picks up that file, generates thumbs, and saves to S3. This works fine and dandy, the only hitch is I want to save image metadata in the same table