public ContentResult Execute() { _taskResetter.ResetHungTasks(); _scheduledTaskRunner.TriggerScheduledTasks(); _queuedTaskRunner.TriggerPendingTasks(); return(new ContentResult { Content = "Executed", ContentType = "text/plain" }); }
public BatchExecutionResult ExecutePendingTasks() { _taskResetter.ResetHungTasks(); IList <QueuedTask> pendingQueuedTasks = _taskQueuer.GetPendingQueuedTasks(); IList <ScheduledTask> pendingScheduledTasks = _taskQueuer.GetPendingScheduledTasks(); IList <IExecutableTask> tasksToExecute = _taskBuilder.GetTasksToExecute(pendingQueuedTasks, pendingScheduledTasks); return(_taskExecutor.Execute(tasksToExecute)); }