1
0
Fork 0
mirror of https://github.com/mperham/sidekiq.git synced 2022-11-09 13:52:34 -05:00
mperham--sidekiq/myapp/Rakefile

15 lines
497 B
Text
Raw Normal View History

2018-06-21 14:14:54 -04:00
# Add your own tasks in files placed in lib/tasks ending in .rake,
# for example lib/tasks/capistrano.rake, and they will automatically be available to Rake.
require_relative "config/application"
2018-06-21 14:14:54 -04:00
Rails.application.load_tasks
task :seed_jobs => :environment do
# see classes defined in config/initializers/sidekiq.rb
[FooJob, BarJob, StoreCardJob, OrderJunkJob, SpamUserJob, FastJob, SlowJob].each do |kls|
(kls.name.size * 10).times do
kls.perform_in(rand * 300)
end
end
end