public static ISchedulerService CreateScheduler() { var bus = RabbitHutch.CreateBus("host=localhost"); return(new SchedulerService( bus, new ScheduleRepository(ScheduleRepositoryConfiguration.FromConfigFile(), () => DateTime.UtcNow), SchedulerServiceConfiguration.FromConfigFile())); }
public static ISchedulerService CreateScheduler() { var bus = RabbitHutch.CreateBus(); var logger = new Logger(LogManager.GetLogger("EasyNetQ.Scheduler")); return(new SchedulerService( bus, logger, new ScheduleRepository(ScheduleRepositoryConfiguration.FromConfigFile(), () => DateTime.UtcNow), SchedulerServiceConfiguration.FromConfigFile())); }
public static ISchedulerService CreateScheduler() { var serviceConfig = SchedulerServiceConfiguration.FromConfigFile(); var bus = RabbitHutch.CreateBus("host=localhost", sr => { if (serviceConfig.EnableLegacyConventions) { sr.EnableLegacyConventions(); } }); return(new SchedulerService( bus, new ScheduleRepository(ScheduleRepositoryConfiguration.FromConfigFile(), () => DateTime.UtcNow), SchedulerServiceConfiguration.FromConfigFile())); }