Friday, August 03, 2007

DNN Schedulers

Writing scheduled tasks in ASP.Net is not a trivial thing. For a start, I haven't written any. So when we had to design a scheduler for Dot Net Nuke (DNN) it appeared even more daunting. DNN is a portal framework built on top of ASP.Net and its the underneath framework being used for the current project I'm working on.

The problem with ASP.Net scheduling is the fact that the ASP.Net worker process gets recycled every now and then. So once the worker process goes down (shutting down any schedulers with it) it will not be up again until someone hits the web site again.  Someone had also suggested writing windows services which operates independent of ASP.Net as schedulers. The recycling of the worker process is a very important feature in which enables the server not to be taken down by runaway applications.  But one downside of this is the impact to the scheduler. But as long as someone is visiting your web site the scheduler will keep on running.

Lucky for me DNN had an inbuilt scheduling engine.  This had almost all the features you would want from a scheduler. It has a easy to implement interface for me write my own scheduling tasks (DotNetNuke.Services.Scheduling.Scheduler interface in DotNetNuke.DNNScheduler.DLL), It has easy to use interfaces for me to configure it and it also provides history views for me to check how my scheduler was performing its tasks.

It was pretty easy for me to implement a simple test scheduler according to DNN documentation. I just have to wait and see what kind of complications could arrive when I implement the real scheduler which is to migrate potential DNN users from a legacy system to the DNN portal on a daily basis.

Post a Comment