Initiating Threads on IIS Start Up

J

John

Hello,

We are trying to implement a solution for a project requirement for
which we need to have multiple services running to support offline
functionality such as the transmission of emails to subscribed users
and the publishing of content on specific schedules. In doing this we
would like to re-use a lot of the libraries we have already built for
the web application and, more specifically, re-use all of the
configuration files which have already been established for the web
application.

One solution for this is to spawn threads within the Application_Start
event of the web application which will run continously and handle the
offline tasks at their set schedules. This is probably the easiest
solution to implement, however the only problem is that these threads
will only be spawned when the first request is made to the web server.

Is there any other event trigger we could work off of that would be
executed when the web service restarts? Also, are there any
complications we should expect in going with this solution, or are
there any better solutions we should be looking into?

Thanks in advance.

John Fleming
 
M

Mark Newmister

You could write a very simple "poll" service that periodically calls (pings)
a web service method.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,766
Messages
2,569,569
Members
45,042
Latest member
icassiem

Latest Threads

Top