public MessageHandler() { _scheduleService = ObjectContainer.Resolve <IScheduleService>(); _scheduleService.StartTask("PrintThroughput", PrintThroughput, 1000, 1000); _logger = ObjectContainer.Resolve <ILoggerFactory>().Create(typeof(Program).Name); _rtStatisticService = ObjectContainer.Resolve <IRTStatisticService>(); }
static void Main(string[] args) { using (var bootstrapper = new AbpBootstrapper()) { bootstrapper.Initialize(); _logger = IocManager.Instance.Resolve <ILoggerFactory>().Create(typeof(Program).Name); _scheduleService = IocManager.Instance.Resolve <IScheduleService>(); _rtStatisticService = IocManager.Instance.Resolve <IRTStatisticService>(); SendMessageTest(); StartPrintThroughputTask(); Console.ReadLine(); } }
static void InitializeEQueue() { ECommonConfiguration .Create() .UseAutofac() .RegisterCommonComponents() .UseLog4Net() .UseJsonNet() .RegisterUnhandledExceptionHandler() .RegisterEQueueComponents() .SetDefault <IQueueSelector, QueueAverageSelector>(); _logger = ObjectContainer.Resolve <ILoggerFactory>().Create(typeof(Program).Name); _scheduleService = ObjectContainer.Resolve <IScheduleService>(); _rtStatisticService = ObjectContainer.Resolve <IRTStatisticService>(); }
public MessageHandler() { _scheduleService = ObjectContainer.Resolve<IScheduleService>(); _scheduleService.StartTask("PrintThroughput", PrintThroughput, 1000, 1000); _logger = ObjectContainer.Resolve<ILoggerFactory>().Create(typeof(Program).Name); _rtStatisticService = ObjectContainer.Resolve<IRTStatisticService>(); }