You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In a typical .NET application, the logger are injected via ILogger<> interface. This allows us to use other logging framework such as Serilog if needed be. Currently, the logging implementation in SFLoggerFactory instantiates the Log4Net implementation in-line as static singleton.
public static SFLogger GetLogger<T>()
{
if (!SFLoggerFactory.isLoggerEnabled)
return (SFLogger) new SFLoggerEmptyImpl();
return SFLoggerFactory.logger == null ? (SFLogger) new Log4NetImpl(LogManager.GetLogger(typeof (T))) : SFLoggerFactory.logger;
}
Configuration
Driver version: 2.0.8
Dotnet framework and version: .NET 6
Expectation
Allow injecting custom implementation of SFLogger independent from Log4Net so it can play nicely with logging framework that is configured in the rest of the application
The text was updated successfully, but these errors were encountered:
Issue description
In a typical .NET application, the logger are injected via ILogger<> interface. This allows us to use other logging framework such as Serilog if needed be. Currently, the logging implementation in
SFLoggerFactory
instantiates the Log4Net implementation in-line as static singleton.Configuration
Driver version: 2.0.8
Dotnet framework and version: .NET 6
Expectation
Allow injecting custom implementation of SFLogger independent from Log4Net so it can play nicely with logging framework that is configured in the rest of the application
The text was updated successfully, but these errors were encountered: