Ok Azure Experts,
I have a task that only needs to run once every week - this is a long running task that can take 2-3 days to run.
I have set up a worker role to scale based on a queue. On the day that we want the task to start - we populate the queue (using a Web Job).
During the rest of the time, when the queue is empty, I want the worker roles to shut down - but I cannot scale down to 0 instances.
Originally, we wanted to do this with a Web Job, but the website shuts down from time to time - abruptly turning off my webjob - is this supposed to happen? Even with
Keep-Alive
turned on? Also, you cannot stop a triggered Web Job from running - so if we want the process to stop - we need to turn off the Web site - not ideal.
How do I scale my instances down to zero?
* Alternatives solutions are also welcome.
Trying to minimize cost here - why pay for a worker role that isn't doing anything?