I've a web job that grab a file from internet and process it. I have tied it s to a scheduler that run everyday at the mid-night.
Sometimes the grab file process fails and throws an exception which crashes the web jobs and stops till the scheduler kicks again next day.
To stop the app from crashing, one option I have is to wrap it with a try-catch block and handle the error. But I want to be able to re-run the web jobs after it fails.
Is there a way for me to tell the azure scheduler to re-run the task for N number of times after it fails?
For example, I want the web jobs to be re-run after 5 minutes of fail for at-most 5 times. I don't want to wait for the scheduler to kick in next day.