This chapter explains how to configure PostSharp Logging to specifically work with different logging frameworks.
PostSharp sends log events, both automatic and manual, to a logging backend which is responsible for outputting them on screen, into a file, database or elsewhere. PostSharp contains logging backends for many different logging frameworks and you can also create your own backend.
These articles explain how to set up PostSharp with various logging frameworks:
- Logging with System.Console
- Logging with System.Diagnostics.TraceSource
- Logging with System.Diagnostics.Trace
- Logging with NLog
- Logging with log4net
- Logging with Serilog
- Logging with ETW
- Logging with Common.Logging
- Logging with Application Insights
- Logging with ASP.NET Core In addition, the following scenarios are supported:
| Section | Description | |---------|-------------| | Building Your Own Logging Backend (Adapter) | This article shows how to write PostSharp Logging output to any logging framework by building your own adapter, named backend in PostSharp jargon. | | Multiplexing Log Output to Several Frameworks | This article explains how to write PostSharp Logging output to several logging frameworks, each possibly with different verbosity. | | Audit Sample | This example shows how to automatically add audit records to your application. | PostSharp Logging can also collect events from many logging frameworks. This is called collecting logs. For details, see Collecting Logs from Other Frameworks.
See Also
Other Resources