Added log entries for starting and stopping the Scheduler process for reasoning purposes.

This commit is contained in:
Thorsten Eckel 2017-08-14 12:03:03 +02:00
parent fbb7161e6b
commit 989b127453

View file

@ -47,6 +47,7 @@ daemon_options = {
name = 'scheduler' name = 'scheduler'
Daemons.run_proc(name, daemon_options) do Daemons.run_proc(name, daemon_options) do
if ARGV.include?('--') if ARGV.include?('--')
ARGV.slice! 0..ARGV.index('--') ARGV.slice! 0..ARGV.index('--')
else else
@ -55,6 +56,12 @@ Daemons.run_proc(name, daemon_options) do
after_fork(dir) after_fork(dir)
Rails.logger.info 'Scheduler started.'
at_exit do
Rails.logger.info 'Scheduler stopped.'
end
require 'scheduler' require 'scheduler'
Scheduler.threads Scheduler.threads
end end