Permalink
Browse files

Clear active AR connections in the background script so it picks up t…

…he new logger.
  • Loading branch information...
bkeepers committed Sep 24, 2008
1 parent e2a726a commit 28a0028d9248d60ed754b2581ede01644bc022b9
Showing with 1 addition and 0 deletions.
  1. +1 −0 lib/delayed/command.rb
View
@@ -34,6 +34,7 @@ def run
logger = Logger.new(File.join(RAILS_ROOT, 'log', 'delayed_job.log'))
logger.level = ActiveRecord::Base.logger.level
ActiveRecord::Base.logger = logger
+ ActiveRecord::Base.clear_active_connections!
logger.info "*** Starting job worker #{Delayed::Job.worker_name}"

0 comments on commit 28a0028

Please sign in to comment.