cartodb-4.29/config/initializers/load_resque.rb
2020-06-15 10:58:47 +08:00

14 lines
453 B
Ruby

require 'resque'
require 'resque/failure/base'
require 'resque/failure/multiple'
require 'resque/failure/redis'
require_dependency 'redis_factory'
# Load automatically all resque files from lib/resque
Dir[Rails.root.join("lib/resque/*.rb")].each {|f| require f}
Resque.redis = RedisFactory.new_connection
Resque::Failure::Multiple.classes = [Resque::Failure::Redis, CartoDB::Logger::RollbarLogger]
Resque::Failure.backend = Resque::Failure::Multiple