Logging.StructuredLog4Net

Logging.StructuredLog4Net provides extension methods to log entries including value/business objects and/or stack trace of the exception. The objects and message template are serialized /formatted using MessageTemplates. Nothing on log4net configuration is required to change. Github source: https://github.com/vndevpro/Logging.StructuredLog4Net


Keywords
Logging, Structured, Log4Net, structured-logging
Install
Install-Package Logging.StructuredLog4Net -Version 1.2.0

Documentation

Logging.StructuredLog4Net

Logging.StructuredLog4Net on NuGet

To install on PM console:

Install-Package Logging.StructuredLog4Net

Usage

Add a using the namespace

using Logging.StructuredLog4Net'

Log as usual similarly to other standard Log4Net methods like:

Logger.Info("Starting", new { ... });

Logger.Error("Starting", new { ... }, ex);