Exemplo n.º 1
0
 public DashboardTaskOperation(DashboardTaskOperationContext context)
     : base(context)
 {
     DashboardTaskClassTypes = context.DashboardTaskClassTypes;
 }
Exemplo n.º 2
0
        protected void StartDashboardTaskEngines()
        {
            try
            {
                Logger.Info("Starting Dashboard Task Engine...", LogCategories.EngineStart,
                ignoreVerbosityConfig: true);

                var dashboardTaskContext = new DashboardTaskOperationContext(
                    SleepIntervalTimeInSeconds,
                    LogCategories.DashboardTask,
                    new TaskThreadSafeDataAccess(),
                    exitStrategy,
                    dashboardTaskTypes,
                    OnScheduledTaskMonitorLooped);

                foreach (var task in WorkerOperationFactory<DashboardTaskOperation>.Construct(dashboardTaskContext))
                {
                    ActiveEngines.Add(task);
                }


                Logger.Info("Dashboard Task Engines started successfully.", LogCategories.EngineStart, ignoreVerbosityConfig: true);
            }
            catch (Exception exception)
            {
                Logger.Fatal("Dashboard Task engines failed to start.", exception);
                throw;
            }
        }