2026-04-08 09:24:52,744 [1] ERROR Spring.Objects.Factory.Support.DefaultListableObjectFactory - GetObjectInternal: error obtaining object &NHibernateSessionFactory 2026-04-08 09:24:52,767 [1] ERROR Startup - Error creating context 'main': Connection refused System.Configuration.ConfigurationErrorsException: Error creating context 'main': Connection refused ---> Spring.Objects.Factory.ObjectCreationException: Error creating object with name 'NHibernateSessionFactory' defined in 'assembly [MCMS.Log.Service, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null], resource [MCMS.Log.Service.Config.Dao_MYSQL.xml] line 26' : Initialization of object failed : Unable to connect to any of the specified MySQL hosts. ---> MySql.Data.MySqlClient.MySqlException (0x80004005): Unable to connect to any of the specified MySQL hosts. ---> System.Net.Sockets.SocketException (111): Connection refused at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.ThrowException(SocketError error, CancellationToken cancellationToken) at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.System.Threading.Tasks.Sources.IValueTaskSource.GetResult(Int16 token) at System.Threading.Tasks.ValueTask.ValueTaskSourceAsTask.<>c.<.cctor>b__4_0(Object state) --- End of stack trace from previous location --- at System.Net.Sockets.TcpClient.CompleteConnectAsync(Task task) at MySql.Data.MySqlClient.NativeDriver.<>c.b__38_0(Exception ex) at System.AggregateException.Handle(Func`2 predicate) at MySql.Data.MySqlClient.NativeDriver.OpenAsync(Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.Driver.OpenAsync(Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.Driver.CreateAsync(MySqlConnectionStringBuilder settings, Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.Driver.CreateAsync(MySqlConnectionStringBuilder settings, Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.MySqlPool.CreateNewPooledConnectionAsync(Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.MySqlPool.InitializeAsync(Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.MySqlPoolManager.GetPoolAsync(MySqlConnectionStringBuilder settings, Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.MySqlConnection.OpenAsync(Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.MySqlConnection.Open() at NHibernate.Connection.DriverConnectionProvider.GetConnection(String connectionString) at NHibernate.Connection.ConnectionProvider.GetConnection() at NHibernate.Tool.hbm2ddl.SuppliedConnectionProviderConnectionHelper.Prepare() at NHibernate.Tool.hbm2ddl.SchemaMetadataUpdater.GetReservedWords(Dialect dialect, IConnectionHelper connectionHelper) at NHibernate.Tool.hbm2ddl.SchemaMetadataUpdater.UpdateDialectKeywords(Dialect dialect, IConnectionHelper connectionHelper) at NHibernate.Tool.hbm2ddl.SchemaMetadataUpdater.Update(ISessionFactoryImplementor sessionFactory) at NHibernate.Impl.SessionFactoryImpl..ctor(Configuration cfg, IMapping mapping, Settings settings, EventListeners listeners) at NHibernate.Cfg.Configuration.BuildSessionFactory() at Spring.Data.NHibernate.LocalSessionFactoryObject.NewSessionFactory(Configuration config) at Spring.Data.NHibernate.LocalSessionFactoryObject.AfterPropertiesSet() at Spring.Objects.Factory.Support.AbstractAutowireCapableObjectFactory.InvokeInitMethods(Object target, String name, IConfigurableObjectDefinition definition) at Spring.Objects.Factory.Support.AbstractAutowireCapableObjectFactory.ConfigureObject(String name, RootObjectDefinition definition, IObjectWrapper wrapper) at Spring.Objects.Factory.Support.AbstractAutowireCapableObjectFactory.InstantiateObject(String name, RootObjectDefinition definition, Object[] arguments, Boolean allowEagerCaching, Boolean suppressConfigure) --- End of inner exception stack trace --- at Spring.Objects.Factory.Support.AbstractAutowireCapableObjectFactory.InstantiateObject(String name, RootObjectDefinition definition, Object[] arguments, Boolean allowEagerCaching, Boolean suppressConfigure) at Spring.Objects.Factory.Support.AbstractObjectFactory.CreateAndCacheSingletonInstance(String objectName, RootObjectDefinition objectDefinition, Object[] arguments) at Spring.Objects.Factory.Support.AbstractObjectFactory.GetObjectInternal(String name, Type requiredType, Object[] arguments, Boolean suppressConfigure) at Spring.Objects.Factory.Support.AbstractObjectFactory.GetObject(String name) at Spring.Objects.Factory.Support.DefaultListableObjectFactory.PreInstantiateSingletons() at Spring.Context.Support.AbstractApplicationContext.Refresh() at Spring.Context.Support.NetCoreContextInstantiator.InvokeContextConstructor(ConstructorInfo ctor) at Spring.Context.Support.ContextInstantiator.InstantiateContext() at Spring.Context.Support.ContextCreater.InstantiateContext(IApplicationContext parentContext, String contextName, Type contextType, Boolean caseSensitive, IList`1 resources) at Spring.Context.Support.ContextCreater.Create(IApplicationContext parent, IConfiguration netCoreConfigObject, String contextElement) --- End of inner exception stack trace --- at Spring.Context.Support.ContextCreater.Create(IApplicationContext parent, IConfiguration netCoreConfigObject, String contextElement) at Spring.Context.Support.ContextCreater.Create(String contextElement) at Spring.Extensions.DependencyInjection.ContextCreaterExtensions.WithSpringReturnContext(IServiceCollection services, IConfiguration configuration, String sectionName, String netCoreConfigObjectName) at Spring.Extensions.DependencyInjection.ContextCreaterExtensions.WithSpring(IServiceCollection services, IConfiguration configuration, String sectionName, String netCoreConfigObjectName) at MCMS.Log.Startup.ConfigureServices(IServiceCollection services) in E:\agent\_work\7\s\MCMS.Log\Startup.cs:line 70 2026-04-08 09:24:52,948 [1] CRITICAL Microsoft.AspNetCore.Hosting.Diagnostics - Application startup exception System.InvalidOperationException: Unable to find the required services. Please add all the required services by calling 'IServiceCollection.AddAuthorization' in the application startup code. at Microsoft.AspNetCore.Builder.AuthorizationAppBuilderExtensions.VerifyServicesRegistered(IApplicationBuilder app) at Microsoft.AspNetCore.Builder.AuthorizationAppBuilderExtensions.UseAuthorization(IApplicationBuilder app) at MCMS.Log.Startup.Configure(IApplicationBuilder app, IWebHostEnvironment env, IHostApplicationLifetime applicationLifetime, ILoggerFactory loggerFactory) in E:\agent\_work\7\s\MCMS.Log\Startup.cs:line 292 at System.RuntimeMethodHandle.InvokeMethod(Object target, Span`1& arguments, Signature sig, Boolean constructor, Boolean wrapExceptions) at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture) at Microsoft.AspNetCore.Hosting.ConfigureBuilder.Invoke(Object instance, IApplicationBuilder builder) at Microsoft.AspNetCore.Hosting.ConfigureBuilder.<>c__DisplayClass4_0.b__0(IApplicationBuilder builder) at Microsoft.AspNetCore.Hosting.GenericWebHostBuilder.<>c__DisplayClass15_0.b__1(IApplicationBuilder app) at Microsoft.AspNetCore.HostFilteringStartupFilter.<>c__DisplayClass0_0.b__0(IApplicationBuilder app) at Microsoft.AspNetCore.Hosting.GenericWebHostService.StartAsync(CancellationToken cancellationToken) 2026-04-08 09:24:55,395 [1] ERROR Spring.Objects.Factory.Support.DefaultListableObjectFactory - GetObjectInternal: error obtaining object &NHibernateSessionFactory 2026-04-08 09:24:55,413 [1] ERROR Startup - Error creating context 'main': Connection refused System.Configuration.ConfigurationErrorsException: Error creating context 'main': Connection refused ---> Spring.Objects.Factory.ObjectCreationException: Error creating object with name 'NHibernateSessionFactory' defined in 'assembly [MCMS.Log.Service, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null], resource [MCMS.Log.Service.Config.Dao_MYSQL.xml] line 26' : Initialization of object failed : Unable to connect to any of the specified MySQL hosts. ---> MySql.Data.MySqlClient.MySqlException (0x80004005): Unable to connect to any of the specified MySQL hosts. ---> System.Net.Sockets.SocketException (111): Connection refused at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.ThrowException(SocketError error, CancellationToken cancellationToken) at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.System.Threading.Tasks.Sources.IValueTaskSource.GetResult(Int16 token) at System.Threading.Tasks.ValueTask.ValueTaskSourceAsTask.<>c.<.cctor>b__4_0(Object state) --- End of stack trace from previous location --- at System.Net.Sockets.TcpClient.CompleteConnectAsync(Task task) at MySql.Data.MySqlClient.NativeDriver.<>c.b__38_0(Exception ex) at System.AggregateException.Handle(Func`2 predicate) at MySql.Data.MySqlClient.NativeDriver.OpenAsync(Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.Driver.OpenAsync(Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.Driver.CreateAsync(MySqlConnectionStringBuilder settings, Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.Driver.CreateAsync(MySqlConnectionStringBuilder settings, Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.MySqlPool.CreateNewPooledConnectionAsync(Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.MySqlPool.InitializeAsync(Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.MySqlPoolManager.GetPoolAsync(MySqlConnectionStringBuilder settings, Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.MySqlConnection.OpenAsync(Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.MySqlConnection.Open() at NHibernate.Connection.DriverConnectionProvider.GetConnection(String connectionString) at NHibernate.Connection.ConnectionProvider.GetConnection() at NHibernate.Tool.hbm2ddl.SuppliedConnectionProviderConnectionHelper.Prepare() at NHibernate.Tool.hbm2ddl.SchemaMetadataUpdater.GetReservedWords(Dialect dialect, IConnectionHelper connectionHelper) at NHibernate.Tool.hbm2ddl.SchemaMetadataUpdater.UpdateDialectKeywords(Dialect dialect, IConnectionHelper connectionHelper) at NHibernate.Tool.hbm2ddl.SchemaMetadataUpdater.Update(ISessionFactoryImplementor sessionFactory) at NHibernate.Impl.SessionFactoryImpl..ctor(Configuration cfg, IMapping mapping, Settings settings, EventListeners listeners) at NHibernate.Cfg.Configuration.BuildSessionFactory() at Spring.Data.NHibernate.LocalSessionFactoryObject.NewSessionFactory(Configuration config) at Spring.Data.NHibernate.LocalSessionFactoryObject.AfterPropertiesSet() at Spring.Objects.Factory.Support.AbstractAutowireCapableObjectFactory.InvokeInitMethods(Object target, String name, IConfigurableObjectDefinition definition) at Spring.Objects.Factory.Support.AbstractAutowireCapableObjectFactory.ConfigureObject(String name, RootObjectDefinition definition, IObjectWrapper wrapper) at Spring.Objects.Factory.Support.AbstractAutowireCapableObjectFactory.InstantiateObject(String name, RootObjectDefinition definition, Object[] arguments, Boolean allowEagerCaching, Boolean suppressConfigure) --- End of inner exception stack trace --- at Spring.Objects.Factory.Support.AbstractAutowireCapableObjectFactory.InstantiateObject(String name, RootObjectDefinition definition, Object[] arguments, Boolean allowEagerCaching, Boolean suppressConfigure) at Spring.Objects.Factory.Support.AbstractObjectFactory.CreateAndCacheSingletonInstance(String objectName, RootObjectDefinition objectDefinition, Object[] arguments) at Spring.Objects.Factory.Support.AbstractObjectFactory.GetObjectInternal(String name, Type requiredType, Object[] arguments, Boolean suppressConfigure) at Spring.Objects.Factory.Support.AbstractObjectFactory.GetObject(String name) at Spring.Objects.Factory.Support.DefaultListableObjectFactory.PreInstantiateSingletons() at Spring.Context.Support.AbstractApplicationContext.Refresh() at Spring.Context.Support.NetCoreContextInstantiator.InvokeContextConstructor(ConstructorInfo ctor) at Spring.Context.Support.ContextInstantiator.InstantiateContext() at Spring.Context.Support.ContextCreater.InstantiateContext(IApplicationContext parentContext, String contextName, Type contextType, Boolean caseSensitive, IList`1 resources) at Spring.Context.Support.ContextCreater.Create(IApplicationContext parent, IConfiguration netCoreConfigObject, String contextElement) --- End of inner exception stack trace --- at Spring.Context.Support.ContextCreater.Create(IApplicationContext parent, IConfiguration netCoreConfigObject, String contextElement) at Spring.Context.Support.ContextCreater.Create(String contextElement) at Spring.Extensions.DependencyInjection.ContextCreaterExtensions.WithSpringReturnContext(IServiceCollection services, IConfiguration configuration, String sectionName, String netCoreConfigObjectName) at Spring.Extensions.DependencyInjection.ContextCreaterExtensions.WithSpring(IServiceCollection services, IConfiguration configuration, String sectionName, String netCoreConfigObjectName) at MCMS.Log.Startup.ConfigureServices(IServiceCollection services) in E:\agent\_work\7\s\MCMS.Log\Startup.cs:line 70 2026-04-08 09:24:55,580 [1] CRITICAL Microsoft.AspNetCore.Hosting.Diagnostics - Application startup exception System.InvalidOperationException: Unable to find the required services. Please add all the required services by calling 'IServiceCollection.AddAuthorization' in the application startup code. at Microsoft.AspNetCore.Builder.AuthorizationAppBuilderExtensions.VerifyServicesRegistered(IApplicationBuilder app) at Microsoft.AspNetCore.Builder.AuthorizationAppBuilderExtensions.UseAuthorization(IApplicationBuilder app) at MCMS.Log.Startup.Configure(IApplicationBuilder app, IWebHostEnvironment env, IHostApplicationLifetime applicationLifetime, ILoggerFactory loggerFactory) in E:\agent\_work\7\s\MCMS.Log\Startup.cs:line 292 at System.RuntimeMethodHandle.InvokeMethod(Object target, Span`1& arguments, Signature sig, Boolean constructor, Boolean wrapExceptions) at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture) at Microsoft.AspNetCore.Hosting.ConfigureBuilder.Invoke(Object instance, IApplicationBuilder builder) at Microsoft.AspNetCore.Hosting.ConfigureBuilder.<>c__DisplayClass4_0.b__0(IApplicationBuilder builder) at Microsoft.AspNetCore.Hosting.GenericWebHostBuilder.<>c__DisplayClass15_0.b__1(IApplicationBuilder app) at Microsoft.AspNetCore.HostFilteringStartupFilter.<>c__DisplayClass0_0.b__0(IApplicationBuilder app) at Microsoft.AspNetCore.Hosting.GenericWebHostService.StartAsync(CancellationToken cancellationToken) 2026-04-08 09:24:58,016 [1] ERROR Spring.Objects.Factory.Support.DefaultListableObjectFactory - GetObjectInternal: error obtaining object &NHibernateSessionFactory 2026-04-08 09:24:58,031 [1] ERROR Startup - Error creating context 'main': Connection refused System.Configuration.ConfigurationErrorsException: Error creating context 'main': Connection refused ---> Spring.Objects.Factory.ObjectCreationException: Error creating object with name 'NHibernateSessionFactory' defined in 'assembly [MCMS.Log.Service, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null], resource [MCMS.Log.Service.Config.Dao_MYSQL.xml] line 26' : Initialization of object failed : Unable to connect to any of the specified MySQL hosts. ---> MySql.Data.MySqlClient.MySqlException (0x80004005): Unable to connect to any of the specified MySQL hosts. ---> System.Net.Sockets.SocketException (111): Connection refused at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.ThrowException(SocketError error, CancellationToken cancellationToken) at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.System.Threading.Tasks.Sources.IValueTaskSource.GetResult(Int16 token) at System.Threading.Tasks.ValueTask.ValueTaskSourceAsTask.<>c.<.cctor>b__4_0(Object state) --- End of stack trace from previous location --- at System.Net.Sockets.TcpClient.CompleteConnectAsync(Task task) at MySql.Data.MySqlClient.NativeDriver.<>c.b__38_0(Exception ex) at System.AggregateException.Handle(Func`2 predicate) at MySql.Data.MySqlClient.NativeDriver.OpenAsync(Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.Driver.OpenAsync(Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.Driver.CreateAsync(MySqlConnectionStringBuilder settings, Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.Driver.CreateAsync(MySqlConnectionStringBuilder settings, Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.MySqlPool.CreateNewPooledConnectionAsync(Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.MySqlPool.InitializeAsync(Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.MySqlPoolManager.GetPoolAsync(MySqlConnectionStringBuilder settings, Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.MySqlConnection.OpenAsync(Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.MySqlConnection.Open() at NHibernate.Connection.DriverConnectionProvider.GetConnection(String connectionString) at NHibernate.Connection.ConnectionProvider.GetConnection() at NHibernate.Tool.hbm2ddl.SuppliedConnectionProviderConnectionHelper.Prepare() at NHibernate.Tool.hbm2ddl.SchemaMetadataUpdater.GetReservedWords(Dialect dialect, IConnectionHelper connectionHelper) at NHibernate.Tool.hbm2ddl.SchemaMetadataUpdater.UpdateDialectKeywords(Dialect dialect, IConnectionHelper connectionHelper) at NHibernate.Tool.hbm2ddl.SchemaMetadataUpdater.Update(ISessionFactoryImplementor sessionFactory) at NHibernate.Impl.SessionFactoryImpl..ctor(Configuration cfg, IMapping mapping, Settings settings, EventListeners listeners) at NHibernate.Cfg.Configuration.BuildSessionFactory() at Spring.Data.NHibernate.LocalSessionFactoryObject.NewSessionFactory(Configuration config) at Spring.Data.NHibernate.LocalSessionFactoryObject.AfterPropertiesSet() at Spring.Objects.Factory.Support.AbstractAutowireCapableObjectFactory.InvokeInitMethods(Object target, String name, IConfigurableObjectDefinition definition) at Spring.Objects.Factory.Support.AbstractAutowireCapableObjectFactory.ConfigureObject(String name, RootObjectDefinition definition, IObjectWrapper wrapper) at Spring.Objects.Factory.Support.AbstractAutowireCapableObjectFactory.InstantiateObject(String name, RootObjectDefinition definition, Object[] arguments, Boolean allowEagerCaching, Boolean suppressConfigure) --- End of inner exception stack trace --- at Spring.Objects.Factory.Support.AbstractAutowireCapableObjectFactory.InstantiateObject(String name, RootObjectDefinition definition, Object[] arguments, Boolean allowEagerCaching, Boolean suppressConfigure) at Spring.Objects.Factory.Support.AbstractObjectFactory.CreateAndCacheSingletonInstance(String objectName, RootObjectDefinition objectDefinition, Object[] arguments) at Spring.Objects.Factory.Support.AbstractObjectFactory.GetObjectInternal(String name, Type requiredType, Object[] arguments, Boolean suppressConfigure) at Spring.Objects.Factory.Support.AbstractObjectFactory.GetObject(String name) at Spring.Objects.Factory.Support.DefaultListableObjectFactory.PreInstantiateSingletons() at Spring.Context.Support.AbstractApplicationContext.Refresh() at Spring.Context.Support.NetCoreContextInstantiator.InvokeContextConstructor(ConstructorInfo ctor) at Spring.Context.Support.ContextInstantiator.InstantiateContext() at Spring.Context.Support.ContextCreater.InstantiateContext(IApplicationContext parentContext, String contextName, Type contextType, Boolean caseSensitive, IList`1 resources) at Spring.Context.Support.ContextCreater.Create(IApplicationContext parent, IConfiguration netCoreConfigObject, String contextElement) --- End of inner exception stack trace --- at Spring.Context.Support.ContextCreater.Create(IApplicationContext parent, IConfiguration netCoreConfigObject, String contextElement) at Spring.Context.Support.ContextCreater.Create(String contextElement) at Spring.Extensions.DependencyInjection.ContextCreaterExtensions.WithSpringReturnContext(IServiceCollection services, IConfiguration configuration, String sectionName, String netCoreConfigObjectName) at Spring.Extensions.DependencyInjection.ContextCreaterExtensions.WithSpring(IServiceCollection services, IConfiguration configuration, String sectionName, String netCoreConfigObjectName) at MCMS.Log.Startup.ConfigureServices(IServiceCollection services) in E:\agent\_work\7\s\MCMS.Log\Startup.cs:line 70 2026-04-08 09:24:58,161 [1] CRITICAL Microsoft.AspNetCore.Hosting.Diagnostics - Application startup exception System.InvalidOperationException: Unable to find the required services. Please add all the required services by calling 'IServiceCollection.AddAuthorization' in the application startup code. at Microsoft.AspNetCore.Builder.AuthorizationAppBuilderExtensions.VerifyServicesRegistered(IApplicationBuilder app) at Microsoft.AspNetCore.Builder.AuthorizationAppBuilderExtensions.UseAuthorization(IApplicationBuilder app) at MCMS.Log.Startup.Configure(IApplicationBuilder app, IWebHostEnvironment env, IHostApplicationLifetime applicationLifetime, ILoggerFactory loggerFactory) in E:\agent\_work\7\s\MCMS.Log\Startup.cs:line 292 at System.RuntimeMethodHandle.InvokeMethod(Object target, Span`1& arguments, Signature sig, Boolean constructor, Boolean wrapExceptions) at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture) at Microsoft.AspNetCore.Hosting.ConfigureBuilder.Invoke(Object instance, IApplicationBuilder builder) at Microsoft.AspNetCore.Hosting.ConfigureBuilder.<>c__DisplayClass4_0.b__0(IApplicationBuilder builder) at Microsoft.AspNetCore.Hosting.GenericWebHostBuilder.<>c__DisplayClass15_0.b__1(IApplicationBuilder app) at Microsoft.AspNetCore.HostFilteringStartupFilter.<>c__DisplayClass0_0.b__0(IApplicationBuilder app) at Microsoft.AspNetCore.Hosting.GenericWebHostService.StartAsync(CancellationToken cancellationToken) 2026-04-08 09:25:00,397 [1] ERROR Spring.Objects.Factory.Support.DefaultListableObjectFactory - GetObjectInternal: error obtaining object &NHibernateSessionFactory 2026-04-08 09:25:00,412 [1] ERROR Startup - Error creating context 'main': Connection refused System.Configuration.ConfigurationErrorsException: Error creating context 'main': Connection refused ---> Spring.Objects.Factory.ObjectCreationException: Error creating object with name 'NHibernateSessionFactory' defined in 'assembly [MCMS.Log.Service, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null], resource [MCMS.Log.Service.Config.Dao_MYSQL.xml] line 26' : Initialization of object failed : Unable to connect to any of the specified MySQL hosts. ---> MySql.Data.MySqlClient.MySqlException (0x80004005): Unable to connect to any of the specified MySQL hosts. ---> System.Net.Sockets.SocketException (111): Connection refused at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.ThrowException(SocketError error, CancellationToken cancellationToken) at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.System.Threading.Tasks.Sources.IValueTaskSource.GetResult(Int16 token) at System.Threading.Tasks.ValueTask.ValueTaskSourceAsTask.<>c.<.cctor>b__4_0(Object state) --- End of stack trace from previous location --- at System.Net.Sockets.TcpClient.CompleteConnectAsync(Task task) at MySql.Data.MySqlClient.NativeDriver.<>c.b__38_0(Exception ex) at System.AggregateException.Handle(Func`2 predicate) at MySql.Data.MySqlClient.NativeDriver.OpenAsync(Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.Driver.OpenAsync(Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.Driver.CreateAsync(MySqlConnectionStringBuilder settings, Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.Driver.CreateAsync(MySqlConnectionStringBuilder settings, Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.MySqlPool.CreateNewPooledConnectionAsync(Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.MySqlPool.InitializeAsync(Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.MySqlPoolManager.GetPoolAsync(MySqlConnectionStringBuilder settings, Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.MySqlConnection.OpenAsync(Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.MySqlConnection.Open() at NHibernate.Connection.DriverConnectionProvider.GetConnection(String connectionString) at NHibernate.Connection.ConnectionProvider.GetConnection() at NHibernate.Tool.hbm2ddl.SuppliedConnectionProviderConnectionHelper.Prepare() at NHibernate.Tool.hbm2ddl.SchemaMetadataUpdater.GetReservedWords(Dialect dialect, IConnectionHelper connectionHelper) at NHibernate.Tool.hbm2ddl.SchemaMetadataUpdater.UpdateDialectKeywords(Dialect dialect, IConnectionHelper connectionHelper) at NHibernate.Tool.hbm2ddl.SchemaMetadataUpdater.Update(ISessionFactoryImplementor sessionFactory) at NHibernate.Impl.SessionFactoryImpl..ctor(Configuration cfg, IMapping mapping, Settings settings, EventListeners listeners) at NHibernate.Cfg.Configuration.BuildSessionFactory() at Spring.Data.NHibernate.LocalSessionFactoryObject.NewSessionFactory(Configuration config) at Spring.Data.NHibernate.LocalSessionFactoryObject.AfterPropertiesSet() at Spring.Objects.Factory.Support.AbstractAutowireCapableObjectFactory.InvokeInitMethods(Object target, String name, IConfigurableObjectDefinition definition) at Spring.Objects.Factory.Support.AbstractAutowireCapableObjectFactory.ConfigureObject(String name, RootObjectDefinition definition, IObjectWrapper wrapper) at Spring.Objects.Factory.Support.AbstractAutowireCapableObjectFactory.InstantiateObject(String name, RootObjectDefinition definition, Object[] arguments, Boolean allowEagerCaching, Boolean suppressConfigure) --- End of inner exception stack trace --- at Spring.Objects.Factory.Support.AbstractAutowireCapableObjectFactory.InstantiateObject(String name, RootObjectDefinition definition, Object[] arguments, Boolean allowEagerCaching, Boolean suppressConfigure) at Spring.Objects.Factory.Support.AbstractObjectFactory.CreateAndCacheSingletonInstance(String objectName, RootObjectDefinition objectDefinition, Object[] arguments) at Spring.Objects.Factory.Support.AbstractObjectFactory.GetObjectInternal(String name, Type requiredType, Object[] arguments, Boolean suppressConfigure) at Spring.Objects.Factory.Support.AbstractObjectFactory.GetObject(String name) at Spring.Objects.Factory.Support.DefaultListableObjectFactory.PreInstantiateSingletons() at Spring.Context.Support.AbstractApplicationContext.Refresh() at Spring.Context.Support.NetCoreContextInstantiator.InvokeContextConstructor(ConstructorInfo ctor) at Spring.Context.Support.ContextInstantiator.InstantiateContext() at Spring.Context.Support.ContextCreater.InstantiateContext(IApplicationContext parentContext, String contextName, Type contextType, Boolean caseSensitive, IList`1 resources) at Spring.Context.Support.ContextCreater.Create(IApplicationContext parent, IConfiguration netCoreConfigObject, String contextElement) --- End of inner exception stack trace --- at Spring.Context.Support.ContextCreater.Create(IApplicationContext parent, IConfiguration netCoreConfigObject, String contextElement) at Spring.Context.Support.ContextCreater.Create(String contextElement) at Spring.Extensions.DependencyInjection.ContextCreaterExtensions.WithSpringReturnContext(IServiceCollection services, IConfiguration configuration, String sectionName, String netCoreConfigObjectName) at Spring.Extensions.DependencyInjection.ContextCreaterExtensions.WithSpring(IServiceCollection services, IConfiguration configuration, String sectionName, String netCoreConfigObjectName) at MCMS.Log.Startup.ConfigureServices(IServiceCollection services) in E:\agent\_work\7\s\MCMS.Log\Startup.cs:line 70 2026-04-08 09:25:00,536 [1] CRITICAL Microsoft.AspNetCore.Hosting.Diagnostics - Application startup exception System.InvalidOperationException: Unable to find the required services. Please add all the required services by calling 'IServiceCollection.AddAuthorization' in the application startup code. at Microsoft.AspNetCore.Builder.AuthorizationAppBuilderExtensions.VerifyServicesRegistered(IApplicationBuilder app) at Microsoft.AspNetCore.Builder.AuthorizationAppBuilderExtensions.UseAuthorization(IApplicationBuilder app) at MCMS.Log.Startup.Configure(IApplicationBuilder app, IWebHostEnvironment env, IHostApplicationLifetime applicationLifetime, ILoggerFactory loggerFactory) in E:\agent\_work\7\s\MCMS.Log\Startup.cs:line 292 at System.RuntimeMethodHandle.InvokeMethod(Object target, Span`1& arguments, Signature sig, Boolean constructor, Boolean wrapExceptions) at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture) at Microsoft.AspNetCore.Hosting.ConfigureBuilder.Invoke(Object instance, IApplicationBuilder builder) at Microsoft.AspNetCore.Hosting.ConfigureBuilder.<>c__DisplayClass4_0.b__0(IApplicationBuilder builder) at Microsoft.AspNetCore.Hosting.GenericWebHostBuilder.<>c__DisplayClass15_0.b__1(IApplicationBuilder app) at Microsoft.AspNetCore.HostFilteringStartupFilter.<>c__DisplayClass0_0.b__0(IApplicationBuilder app) at Microsoft.AspNetCore.Hosting.GenericWebHostService.StartAsync(CancellationToken cancellationToken) 2026-04-08 09:25:02,754 [1] ERROR Spring.Objects.Factory.Support.DefaultListableObjectFactory - GetObjectInternal: error obtaining object &NHibernateSessionFactory 2026-04-08 09:25:02,770 [1] ERROR Startup - Error creating context 'main': Connection refused System.Configuration.ConfigurationErrorsException: Error creating context 'main': Connection refused ---> Spring.Objects.Factory.ObjectCreationException: Error creating object with name 'NHibernateSessionFactory' defined in 'assembly [MCMS.Log.Service, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null], resource [MCMS.Log.Service.Config.Dao_MYSQL.xml] line 26' : Initialization of object failed : Unable to connect to any of the specified MySQL hosts. ---> MySql.Data.MySqlClient.MySqlException (0x80004005): Unable to connect to any of the specified MySQL hosts. ---> System.Net.Sockets.SocketException (111): Connection refused at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.ThrowException(SocketError error, CancellationToken cancellationToken) at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.System.Threading.Tasks.Sources.IValueTaskSource.GetResult(Int16 token) at System.Threading.Tasks.ValueTask.ValueTaskSourceAsTask.<>c.<.cctor>b__4_0(Object state) --- End of stack trace from previous location --- at System.Net.Sockets.TcpClient.CompleteConnectAsync(Task task) at MySql.Data.MySqlClient.NativeDriver.<>c.b__38_0(Exception ex) at System.AggregateException.Handle(Func`2 predicate) at MySql.Data.MySqlClient.NativeDriver.OpenAsync(Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.Driver.OpenAsync(Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.Driver.CreateAsync(MySqlConnectionStringBuilder settings, Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.Driver.CreateAsync(MySqlConnectionStringBuilder settings, Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.MySqlPool.CreateNewPooledConnectionAsync(Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.MySqlPool.InitializeAsync(Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.MySqlPoolManager.GetPoolAsync(MySqlConnectionStringBuilder settings, Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.MySqlConnection.OpenAsync(Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.MySqlConnection.Open() at NHibernate.Connection.DriverConnectionProvider.GetConnection(String connectionString) at NHibernate.Connection.ConnectionProvider.GetConnection() at NHibernate.Tool.hbm2ddl.SuppliedConnectionProviderConnectionHelper.Prepare() at NHibernate.Tool.hbm2ddl.SchemaMetadataUpdater.GetReservedWords(Dialect dialect, IConnectionHelper connectionHelper) at NHibernate.Tool.hbm2ddl.SchemaMetadataUpdater.UpdateDialectKeywords(Dialect dialect, IConnectionHelper connectionHelper) at NHibernate.Tool.hbm2ddl.SchemaMetadataUpdater.Update(ISessionFactoryImplementor sessionFactory) at NHibernate.Impl.SessionFactoryImpl..ctor(Configuration cfg, IMapping mapping, Settings settings, EventListeners listeners) at NHibernate.Cfg.Configuration.BuildSessionFactory() at Spring.Data.NHibernate.LocalSessionFactoryObject.NewSessionFactory(Configuration config) at Spring.Data.NHibernate.LocalSessionFactoryObject.AfterPropertiesSet() at Spring.Objects.Factory.Support.AbstractAutowireCapableObjectFactory.InvokeInitMethods(Object target, String name, IConfigurableObjectDefinition definition) at Spring.Objects.Factory.Support.AbstractAutowireCapableObjectFactory.ConfigureObject(String name, RootObjectDefinition definition, IObjectWrapper wrapper) at Spring.Objects.Factory.Support.AbstractAutowireCapableObjectFactory.InstantiateObject(String name, RootObjectDefinition definition, Object[] arguments, Boolean allowEagerCaching, Boolean suppressConfigure) --- End of inner exception stack trace --- at Spring.Objects.Factory.Support.AbstractAutowireCapableObjectFactory.InstantiateObject(String name, RootObjectDefinition definition, Object[] arguments, Boolean allowEagerCaching, Boolean suppressConfigure) at Spring.Objects.Factory.Support.AbstractObjectFactory.CreateAndCacheSingletonInstance(String objectName, RootObjectDefinition objectDefinition, Object[] arguments) at Spring.Objects.Factory.Support.AbstractObjectFactory.GetObjectInternal(String name, Type requiredType, Object[] arguments, Boolean suppressConfigure) at Spring.Objects.Factory.Support.AbstractObjectFactory.GetObject(String name) at Spring.Objects.Factory.Support.DefaultListableObjectFactory.PreInstantiateSingletons() at Spring.Context.Support.AbstractApplicationContext.Refresh() at Spring.Context.Support.NetCoreContextInstantiator.InvokeContextConstructor(ConstructorInfo ctor) at Spring.Context.Support.ContextInstantiator.InstantiateContext() at Spring.Context.Support.ContextCreater.InstantiateContext(IApplicationContext parentContext, String contextName, Type contextType, Boolean caseSensitive, IList`1 resources) at Spring.Context.Support.ContextCreater.Create(IApplicationContext parent, IConfiguration netCoreConfigObject, String contextElement) --- End of inner exception stack trace --- at Spring.Context.Support.ContextCreater.Create(IApplicationContext parent, IConfiguration netCoreConfigObject, String contextElement) at Spring.Context.Support.ContextCreater.Create(String contextElement) at Spring.Extensions.DependencyInjection.ContextCreaterExtensions.WithSpringReturnContext(IServiceCollection services, IConfiguration configuration, String sectionName, String netCoreConfigObjectName) at Spring.Extensions.DependencyInjection.ContextCreaterExtensions.WithSpring(IServiceCollection services, IConfiguration configuration, String sectionName, String netCoreConfigObjectName) at MCMS.Log.Startup.ConfigureServices(IServiceCollection services) in E:\agent\_work\7\s\MCMS.Log\Startup.cs:line 70 2026-04-08 09:25:02,895 [1] CRITICAL Microsoft.AspNetCore.Hosting.Diagnostics - Application startup exception System.InvalidOperationException: Unable to find the required services. Please add all the required services by calling 'IServiceCollection.AddAuthorization' in the application startup code. at Microsoft.AspNetCore.Builder.AuthorizationAppBuilderExtensions.VerifyServicesRegistered(IApplicationBuilder app) at Microsoft.AspNetCore.Builder.AuthorizationAppBuilderExtensions.UseAuthorization(IApplicationBuilder app) at MCMS.Log.Startup.Configure(IApplicationBuilder app, IWebHostEnvironment env, IHostApplicationLifetime applicationLifetime, ILoggerFactory loggerFactory) in E:\agent\_work\7\s\MCMS.Log\Startup.cs:line 292 at System.RuntimeMethodHandle.InvokeMethod(Object target, Span`1& arguments, Signature sig, Boolean constructor, Boolean wrapExceptions) at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture) at Microsoft.AspNetCore.Hosting.ConfigureBuilder.Invoke(Object instance, IApplicationBuilder builder) at Microsoft.AspNetCore.Hosting.ConfigureBuilder.<>c__DisplayClass4_0.b__0(IApplicationBuilder builder) at Microsoft.AspNetCore.Hosting.GenericWebHostBuilder.<>c__DisplayClass15_0.b__1(IApplicationBuilder app) at Microsoft.AspNetCore.HostFilteringStartupFilter.<>c__DisplayClass0_0.b__0(IApplicationBuilder app) at Microsoft.AspNetCore.Hosting.GenericWebHostService.StartAsync(CancellationToken cancellationToken) 2026-04-08 09:25:06,902 [1] DEBUG Startup - 项目运行环境(.NET 6.0.25):【日志微服务测试环境】 2026-04-08 09:25:07,471 [1] INFO Startup - 【应用程序启动成功】 2026-04-08 09:25:22,535 [23] WARN Microsoft.AspNetCore.HttpsPolicy.HttpsRedirectionMiddleware - Failed to determine the https port for redirect.