protected void taskActionWrapper()
{
taskAction();
TaskEnded = DateTime.UtcNow;
lock (syncLock)
{
TaskRunning = false;
if (ShuttingDown)
// Signal this Timer no longer needs to run - let ASP.Net know it can be killed and cleaned up
System.Web.Hosting.HostingEnvironment.UnregisterObject(this);
}
}