We're running continuous Web Jobs under a WebApp that is set to AlwaysOn
.
One of the jobs, perhaps badly written, is set to run in a loop as long as there are items in an Azure Storage queue, and this queue is being populated faster than the job can consume - effectively making the loop infinite. I want to sometimes stop this job manually.
In the Azure Management Portal (manage.windowsazure.com), I've "Stopped" the job and restarted the WebApp, but the job still seems to be running. How exactly does Azure stop/kill a job?
Apparently it creates a 'disable.job' file in the job directory to signal not to runit, but that of course doesn't get checked until the next startup of the job, which never happens since it's in an infinite loop. Restarting the WebApp doesn't seem to help either.
The only thing that seems to help is when we redeploy which includes swapping with a staging environment (shutting down the previous one with the running job).