Esempio n. 1
0
 public ContentResult Execute()
 {
     _taskResetter.ResetHungTasks();
     _scheduledTaskRunner.TriggerScheduledTasks();
     _queuedTaskRunner.TriggerPendingTasks();
     return(new ContentResult {
         Content = "Executed", ContentType = "text/plain"
     });
 }
Esempio n. 2
0
        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));
        }