How to perform periodic work on an ASP.NET MVC website?

后端 未结 4 544
深忆病人
深忆病人 2020-12-06 01:04

Once a day, I want my ASP.NET MVC4 website, which may be running on multiple servers, to email a report to me. This seems like a pretty common thing to want to do, but I\'m

4条回答
  •  难免孤独
    2020-12-06 01:41

    The proper solution is to create a background service that runs independently of your website. However, if that is not an option there is a hack where you can use the cache as explained in Easy Background Tasks in ASP.NET by Jeff Atwood.

提交回复
热议问题