Skip to content

Repository files navigation

Serilog.Enrichers.ExceptionProperties

Enriches Serilog events with Exception properties when Exceptions are logged. The included properties are Message, Stacktrace, and InnerException.Message. They are enhanced as Exception, Stacktrace, and InnerException properties respectively.

To use the enricher, first install the NuGet package:

Install-Package Serilog.Enrichers.ExceptionProperties

Then, apply the enricher to your LoggerConfiguration:

Log.Logger = new LoggerConfiguration()
  .Enrich.WithExceptionProperties()
  // ...other configuration...
  .CreateLogger();

Copyright (c) Eric Rushing 2022 - Provided under the Apache License, Version 2.0.

About

Enriches Serilog log events by adding exception properties when the log event includes an exception.

Topics

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages