开发者

How to do asynchronous/independent handling of webpage request?

I'm looking to generate a set of images as a result of a user submitting a form on an ASP.net web page. There's a risk that the server will be overloaded with requests so I'm looking for some way of handing off the image generation to a separate process which does the generation and emails the user when they're ready for download. Ideally the separate process would be continuously running so that it can respond to requests promptly.

Any ideas what to use here? Needs to be .net.

Cheers, 开发者_开发知识库Ian.


I would create a Java Servlet and some class with a quartz scheduler that will handle the background jobs.

If a user submits the form you can create the background jobs, quartz will then handle the queuing and processing of those jobs.

You could then have the JavaScript client ask from time to time (every 10 seconds or so) if the jobs are finished and if so, return the urls to the pictures.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜