开发者

How to run a web page(aspx) doing a functionality, triggered by windows task scheduler in a new thread?

I have a situation in which i am fetching top row from a temporary table and doing a functionality using that details. The temporary table will be updated with the new uploaded file details. I do have an aspx page which does this functionality. The web page is triggered using a task scheduler at some interval of开发者_如何转开发 time. My problem is that when the page is triggered

during a schedule if the functionality is not finished before the next trigger the task scheduler gets stuck and won't work unless a new schedule is created.

I have heard that executing the functionality using asp.net threading can solve my problem. Is that possible for my situation? If so any one please help me with code how i can proceed..

Now i just fetch only one top row to do the process. If i can implement this for top few rows (say top 5 rows) then i can increase the speed of my application. Please suggest a solution to implement this as well..


  1. increase the time scheduler time a little bit to it can get completed before another starts.
  2. Improve the update query, so it can save time.
  3. Threading is good idea. But...
  4. Each scheduler should check if the previous one is already running or not, you can put a status of (running/ completed) somewhere in table.
  5. Log scheduler activity (start, end, elapsed time etc), it will help a lot.
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜