commit
df03275eaa
1 changed files with 13 additions and 0 deletions
|
@ -1 +1,14 @@
|
||||||
require 'resque/tasks'
|
require 'resque/tasks'
|
||||||
|
|
||||||
|
# Fix Exception
|
||||||
|
# ActiveRecord::StatementInvalid
|
||||||
|
# Error
|
||||||
|
# PGError: ERROR: prepared statement "a3" already exists
|
||||||
|
task "resque:setup" => :environment do
|
||||||
|
Resque.after_fork do |job|
|
||||||
|
ActiveRecord::Base.establish_connection
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
desc "Alias for resque:work (To run workers on Heroku)"
|
||||||
|
task "jobs:work" => "resque:work"
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue