I recently added a delayed_job rap to my after_restart phase. Like so :
system "script/delayed_job stop"
system "script/delayed_job start -n 3"
Which works for the most part. Until I ran into a little snag today. I found an instance of delayed_job still running even after I repeatedly and manually did script/delayed_job stop
.
I still get this :
user@ip-10-126-6-125 /data/HQ_Channel2/current $ ps aux | grep del
user 11034 0.0 3.4 74016 61964 ? S Dec05 0:19 delayed_job.0
user 11036 0.0 3.5 73660 63516 ? S Dec05 0:21 delayed_job.1
user 11038 0.0 3.6 73980 65256 ? S Dec05 0:17 delayed_job.2
Is it improper of me to be trying to close this via script/delayed_job stop
?
The only other way I know how to kill this is with a kill -9
, but isn't this overkill? And what's more, how would I implement that dynamically?