[Backgroundrb-devel] one more suggestion for backgroundrb

Ezra Zygmuntowicz ezmobius at gmail.com
Wed Jun 21 19:09:47 EDT 2006


On Jun 21, 2006, at 3:12 PM, Charles Brian Quinn wrote:

> Can we name that logger something different since it goes to the  
> log/backgroundrb.log file instead of one of the dev/test/prod  
> logs?  Just a suggestion....  Great fix, though, awesome.
>
> There was another post that came by in June with code to fully load  
> the entire Rails environment  -- versus loading up just the  
> ActiveRecord connection:
>
> -if CONFIG['load_rails']
> -  ActiveRecord::Base.establish_connection(YAML.load(ERB.new(IO.read 
> ("#{RAILS_ROOT}/#{CONFIG['databse_yml']}")).result)[CONFIG 
> ['environment']])
> -end
>
> +if CONFIG['load_rails']
> +  require "#{RAILS_ROOT}/config/environment"
> +end
>
> It was silently failing for me when loading up models that included  
> required classes or utilized includes, such as a model that has:   
> require 'net-ssh' or something like that.  It was mentioned that  
> this does use a lot of memory -- it's true, perhaps this could be  
> another option?  load_full_rails: true  or document the use of  
> loading up required modules too?
>
> One more request -- does the rake backgroundrb:start task read the  
> config file for the environment -- I still have to use:   
> RAILS_ENV="production" rake backgroundrb:start to get it to load in  
> production mode.  Though, you may fix this in your move to stub the  
> scripts.
>
> Great work Ezra, we're having fun with your backgroundrb, and have  
> a blog article coming out on it soon.  Thanks!
>

>
>         Any feature requests for my hack fest?
>
> Cheers-
> -Ezra
>
> -- 
> Charles Brian Quinn
> www.seebq.com

Charles-

	So how would you like the logger to behave? Do you mean having it  
write into the rails dev and prod log files? Or just an option to  
rename it to something else? I will flesh out the config file and its  
related parser to make it much more flexible and tunable when I  
refactor things. Also will be adding a windows service ability.

-Ezra
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://rubyforge.org/pipermail/backgroundrb-devel/attachments/20060621/81dcf61e/attachment.html 


More information about the Backgroundrb-devel mailing list