Beispiel #1
0
 public static ITaskSeriesTimer CreateTimer(IRecurrentCommand command, TimeSpan initialInterval,
     TimeSpan delayInterval, IBackgroundExceptionDispatcher backgroundExceptionDispatcher)
 {
     IDelayStrategy delayStrategy = new FixedDelayStrategy(delayInterval);
     ITaskSeriesCommand timerCommand = new RecurrentTaskSeriesCommand(command, delayStrategy);
     return new TaskSeriesTimer(timerCommand, backgroundExceptionDispatcher, Task.Delay(initialInterval));
 }
 public static ITaskSeriesTimer CreateTimer(IRecurrentCommand command, TimeSpan normalInterval,
     TimeSpan minimumInterval, IBackgroundExceptionDispatcher backgroundExceptionDispatcher)
 {
     IDelayStrategy delayStrategy = new LinearSpeedupStrategy(normalInterval, minimumInterval);
     ITaskSeriesCommand timerCommand = new RecurrentTaskSeriesCommand(command, delayStrategy);
     return new TaskSeriesTimer(timerCommand, backgroundExceptionDispatcher, Task.Delay(normalInterval));
 }
Beispiel #3
0
        public static ITaskSeriesTimer CreateTimer(IRecurrentCommand command, TimeSpan initialInterval,
                                                   TimeSpan delayInterval, IWebJobsExceptionHandler exceptionHandler)
        {
            IDelayStrategy     delayStrategy = new FixedDelayStrategy(delayInterval);
            ITaskSeriesCommand timerCommand  = new RecurrentTaskSeriesCommand(command, delayStrategy);

            return(new TaskSeriesTimer(timerCommand, exceptionHandler, Task.Delay(initialInterval)));
        }
        public static ITaskSeriesTimer CreateTimer(IRecurrentCommand command, TimeSpan normalInterval,
                                                   TimeSpan minimumInterval, IBackgroundExceptionDispatcher backgroundExceptionDispatcher)
        {
            IDelayStrategy     delayStrategy = new LinearSpeedupStrategy(normalInterval, minimumInterval);
            ITaskSeriesCommand timerCommand  = new RecurrentTaskSeriesCommand(command, delayStrategy);

            return(new TaskSeriesTimer(timerCommand, backgroundExceptionDispatcher, Task.Delay(normalInterval)));
        }
Beispiel #5
0
        public static ITaskSeriesTimer CreateTimer(IRecurrentCommand command, TimeSpan normalInterval,
                                                   TimeSpan minimumInterval, IWebJobsExceptionHandler exceptionHandler)
        {
            IDelayStrategy     delayStrategy = new LinearSpeedupStrategy(normalInterval, minimumInterval);
            ITaskSeriesCommand timerCommand  = new RecurrentTaskSeriesCommand(command, delayStrategy);

            return(new TaskSeriesTimer(timerCommand, exceptionHandler, Task.Delay(normalInterval)));
        }