예제 #1
0
        public static void Main(string[] args)
        {
            Console.Title = "MyJetWallet Service.SmsSender";

            Settings = SettingsReader.GetSettings <SettingsModel>(SettingsFileName);

            using var loggerFactory = LogConfigurator.ConfigureElk("MyJetWallet", Settings.SeqServiceUrl, Settings.ElkLogs);

            var logger = loggerFactory.CreateLogger <Program>();

            LogFactory = loggerFactory;

            try
            {
                logger.LogInformation("Application is being started");

                CreateHostBuilder(loggerFactory, args).Build().Run();

                logger.LogInformation("Application has been stopped");
            }
            catch (Exception ex)
            {
                logger.LogCritical(ex, "Application has been terminated unexpectedly");
            }
        }