- Notifications
You must be signed in to change notification settings - Fork150
NLog as Logging Provider for Microsoft Extension Logging
License
NLog/NLog.Extensions.Logging
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
NLog.Extensions.Logging enables NLog as Logging Provider forMicrosoft ILogger-abstraction and Dependency Injection.
- Introduces
AddNLog()
extension methods to register NLog as LoggingProvider for Microsoft Extension Logging. - Introduces${configsetting} for doing lookup of appsettings.json configuration settings.
- Adds support for loadingNLog Configuration from appsettings.json
Notice the standardNLog NuGet package is enough for using NLog Logger with simple console application on the .NET Core platform.Just configure NLog usingFluent Setup API or addNLog.config
file to the project, and follow thetutorial for usingGetCurrentClassLogger()
.
NLog.Extensions.Hosting introducesUseNLog()
as extension-method for the application HostBuilder,and includes the layoutrenderers${host-rootdir}
+${host-environment}
+${host-appname}
.
Note if usingASP.NET Core then instead installNLog.Web.AspNetCore.
About
NLog as Logging Provider for Microsoft Extension Logging
Topics
Resources
License
Uh oh!
There was an error while loading.Please reload this page.