Skip to content

Commit

Permalink
Revert "Parallelize stop and restart to be faster with many workers."
Browse files Browse the repository at this point in the history
Daemons has major issues dealing with threaded daemonizing
This reverts commit 7757209.
  • Loading branch information
albus522 committed Jul 30, 2013
1 parent 44edd94 commit cf20859
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions lib/delayed/command.rb
Expand Up @@ -78,14 +78,10 @@ def daemonize
process_name = "delayed_job.#{@options[:identifier]}"
run_process(process_name, dir)
else
threads = []
worker_count.times do |worker_index|
threads << Thread.start do
process_name = worker_count == 1 ? "delayed_job" : "delayed_job.#{worker_index}"
run_process(process_name, dir)
end
process_name = worker_count == 1 ? "delayed_job" : "delayed_job.#{worker_index}"
run_process(process_name, dir)
end
threads.each(&:join)
end
end

Expand Down

0 comments on commit cf20859

Please sign in to comment.