question

ashwanikumar-8198 avatar image
0 Votes"
ashwanikumar-8198 asked TakahitoIwasa commented

Max timeout limit for Azure Web Job. Is it possible to run long running web jobs for around 2- 3 hours?


I have a scenario where I need to consume third party dll to validate set of input records(10k).

Currently – DLL is taking around 2 hours(120 Mins) to process the file. We don’t have control over dll for optimization or splitting records.

As per my understanding Azure Web Job is right service for handling task – As I haven’t handled that scenario in the past – need expert advice before committing or starting task.

I tried to found long running max timeout limit for Azure Web Jobs, but unfortunately unable to get.

Appreciate if you could provide input if a Azure Web Jobs(task/thread) can run for more than 2-3 hours without timeout issue.

azure-webapps-webjobs
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

1 Answer

TakahitoIwasa avatar image
1 Vote"
TakahitoIwasa answered TakahitoIwasa commented

Hi.

I tried running an infinite log output process in a web job. It can be continued for 2 - 3 hours.
However, there are some things to keep in mind according to the documentation.

In particular, the Kudu page below will be helpful to you.
https://github.com/projectkudu/kudu/wiki/WebJobs

[WEBJOBS_IDLE_TIMEOUT]

If you enter a wait state while running, the process will be aborted after 120 seconds by default.
If the DB processing wait becomes long, it may be affected in your scenario.
It can be extended by updating the "WEBJOBS_IDLE_TIMEOUT" value.

[Graceful Shutdown]

Azure web jobs may receive process shutdown notifications.
For triggered processes, you can change the default behavior by changing the "stopping_wait_time" setting.
However, it seems that a hard shutdown that causes a restart of the web application (such as updating the VM) cannot be avoided.



My final opinion is that it can running for 2 - 3 hours, but it is not guaranteed.
It is safest to implement the process on the assumption that it will be interrupted so that if it is interrupted for any reason, it can be rolled back or restarted from where it was interrupted.


· 1
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.