AsyncTimeoutAttribute is not working with Controller Actions

时间:2015-10-30 23:28:41

标签: asp.net asp.net-mvc iis

We tried to use the following code to increase request timeout for our backup process which runs on IIS and ASP.NET MVC: [AsyncTimeout(79200000)] public async Task<ActionResult> DailyBackup(Guid secret) { HttpContext.Server.ScriptTimeout = 22*3600; await Backups.Create(); return null; } However, this didn't change the timeout and after a short period of time, ASP.NET MVC returns us an empty page and await Backups.Create() is continue to run separately in background. What should we do in order to increase timeout for certain actions without changing our Web.Config file?

0 个答案:

没有答案