public static TaskConfiguration <MonitorWorkItem> IncludeElmah(this TaskConfiguration <MonitorWorkItem> task)
        {
            if (task == null)
            {
                throw new ArgumentNullException(nameof(task));
            }

            return(task.Step <ExportElmahErrorsStep>());
        }
        public static TaskConfiguration <MonitorWorkItem> IncludeMongoDb(this TaskConfiguration <MonitorWorkItem> task)
        {
            if (task == null)
            {
                throw new ArgumentNullException(nameof(task));
            }

            return(task.Step <PingMongoDbStep>());
        }
        public static TaskConfiguration <MaintenanceWorkItem> IncludeMongoDb(this TaskConfiguration <MaintenanceWorkItem> task)
        {
            if (task == null)
            {
                throw new ArgumentNullException(nameof(task));
            }

            return(task.Step <LogRotatorStep>());
        }
        public static TaskConfiguration <MaintenanceWorkItem> IncludeElmah(this TaskConfiguration <MaintenanceWorkItem> task)
        {
            if (task == null)
            {
                throw new ArgumentNullException(nameof(task));
            }

            return(task.Step <CleanUpElmahErrorsStep>());
        }
Exemplo n.º 5
0
        public static TaskConfiguration <MaintenanceWorkItem> IncludeUCommerce(this TaskConfiguration <MaintenanceWorkItem> task)
        {
            if (task == null)
            {
                throw new ArgumentNullException(nameof(task));
            }

            task.Application.UseUCommerce();

            return(task
                   .Step <UCommerceIndexMaintenanceStep>());
        }
        public static TasksConfiguration MaintenanceTask(this TasksConfiguration configuration, Action <TaskConfiguration <MaintenanceWorkItem> > task = null)
        {
            if (configuration == null)
            {
                throw new ArgumentNullException("configuration");
            }
            TaskConfiguration <MaintenanceWorkItem> taskConfiguration = null;

            configuration = configuration.Task <MaintenanceTask, MaintenanceWorkItem>((TaskConfiguration <MaintenanceWorkItem> x) => taskConfiguration = x);
            taskConfiguration.Step <CleanUpIntegrationDbStep>().Step <CleanUpArchivesStep>().Step <ArchiveFoldersStep>();
            if (task != null)
            {
                task(taskConfiguration);
            }
            return(configuration);
        }
Exemplo n.º 7
0
        public static TasksConfiguration MonitorTask(this TasksConfiguration configuration, Action <TaskConfiguration <MonitorWorkItem> > task = null)
        {
            if (configuration == null)
            {
                throw new ArgumentNullException("configuration");
            }
            TaskConfiguration <MonitorWorkItem> taskConfiguration = null;

            configuration = configuration.Task <MonitorTask, MonitorWorkItem>((TaskConfiguration <MonitorWorkItem> x) => taskConfiguration = x);
            taskConfiguration.Step <ExportIntegrationErrorsStep>().Step <MonitorFoldersStep>().Step <PingUrlsStep>();
            if (task != null)
            {
                task(taskConfiguration);
            }
            return(configuration);
        }
        public static TasksConfiguration MonitorTask(this TasksConfiguration configuration, Action <TaskConfiguration <MonitorWorkItem> > task = null)
        {
            if (configuration == null)
            {
                throw new ArgumentNullException(nameof(configuration));
            }

            TaskConfiguration <MonitorWorkItem> localConfiguration = null;

            configuration = configuration
                            .Task <MonitorTask, MonitorWorkItem>(x => localConfiguration = x);

            localConfiguration
            .Step <MonitorFoldersStep>()
            .Step <PingUrlsStep>()
            .Step <ExportIntegrationErrorsStep>();

            task?.Invoke(localConfiguration);

            return(configuration);
        }
        public static TasksConfiguration MaintenanceTask(this TasksConfiguration configuration, Action <TaskConfiguration <MaintenanceWorkItem> > task = null)
        {
            if (configuration == null)
            {
                throw new ArgumentNullException(nameof(configuration));
            }

            TaskConfiguration <MaintenanceWorkItem> taskConfiguration = null;

            configuration = configuration
                            .Task <MaintenanceTask, MaintenanceWorkItem>(x => taskConfiguration = x);

            taskConfiguration
            .Step <CleanUpIntegrationDbStep>()
            .Step <CleanUpDbDistributedMutexStep>()
            .Step <CleanUpArchivesStep>()
            .Step <ArchiveFoldersStep>();

            task?.Invoke(taskConfiguration);

            return(configuration);
        }
 public static TaskConfiguration <MonitorWorkItem> IncludeMongoDb <TConnection>(this TaskConfiguration <MonitorWorkItem> task)
     where TConnection : Connection
 {
     return(task.Step <PingMongoDbStep <TConnection> >());
 }
 public static TaskConfiguration <MaintenanceWorkItem> IncludeMongoDb <TConnection>(this TaskConfiguration <MaintenanceWorkItem> task)
     where TConnection : Connection
 {
     return(task.Step <LogRotatorStep <TConnection> >());
 }
 public static TaskConfiguration <MonitorWorkItem> IncludeElasticsearch <TConnection>(this TaskConfiguration <MonitorWorkItem> task)
     where TConnection : Connection
 {
     return(task.Step <PingElasticsearchStep <TConnection> >());
 }