protected void Application_Start(object sender, EventArgs e)
        {
            var container = new Bootstrapper().Build();

            AutofacHostFactory.Container = container;
            SettingAddress.Initialize(container.Resolve <IAddressRepository>());
            InitializeSettingsService.InitializeConstants();
        }
 protected override void OnStart(string[] args)
 {
     try
     {
         eventLog.WriteEntry("Starting OrderCloudFeed Service");
         InitializeSettingsService.InitializeConstants();
         _service           = new OrderCloudFeedService(eventLog);
         _cancellationToken = new CancellationTokenSource();
         _updateOrderTask   = Task.Run(() => DoTask(_cancellationToken.Token));
         eventLog.WriteEntry("Started OrderCloudFeed Service");
     }
     catch (Exception ex)
     {
         eventLog.WriteEntry(ex.Message + " -ST- " + ex.StackTrace, EventLogEntryType.Error);
     }
 }