Class ThreadAbortExceptionEnricher
Enriches the log if there are ThreadAbort exceptions and will automatically create a minidump if it can
Inheritance
object
Namespace: Umbraco.Cms.Core.Logging.Serilog.Enrichers
Assembly: Umbraco.Infrastructure.dll
Syntax
public class ThreadAbortExceptionEnricher : ILogEventEnricher
Constructors
View SourceThreadAbortExceptionEnricher(IOptionsMonitor<CoreDebugSettings>, IHostingEnvironment, IMarchal)
Initializes a new instance of the ThreadAbortExceptionEnricher class.
Declaration
public ThreadAbortExceptionEnricher(IOptionsMonitor<CoreDebugSettings> coreDebugSettings, IHostingEnvironment hostingEnvironment, IMarchal marchal)
Parameters
| Type | Name | Description |
|---|---|---|
| IOptionsMonitor<CoreDebugSettings> | coreDebugSettings | The monitor for core debug settings. |
| IHostingEnvironment | hostingEnvironment | The current hosting environment. |
| IMarchal | marchal | The marshal instance used for thread operations. |
Methods
View SourceEnrich(LogEvent, ILogEventPropertyFactory)
Enriches the log event with additional information related to thread abort exceptions. This enrichment is applied only when the log event level is Error or Fatal.
Declaration
public void Enrich(LogEvent logEvent, ILogEventPropertyFactory propertyFactory)
Parameters
| Type | Name | Description |
|---|---|---|
| LogEvent | logEvent | The log event to enrich. If the event represents a thread abort exception at Error or Fatal level, additional properties are added. |
| ILogEventPropertyFactory | propertyFactory | The factory used to create log event properties. |