ProcessEnricherServiceCollectionExtensions.AddProcessLogEnricher Method

Definition

Overloads

AddProcessLogEnricher(IServiceCollection)

Source:
ProcessEnricherServiceCollectionExtensions.cs

Adds an instance of the process enricher to the IServiceCollection.

C#
public static Microsoft.Extensions.DependencyInjection.IServiceCollection AddProcessLogEnricher(this Microsoft.Extensions.DependencyInjection.IServiceCollection services);

Parameters

services
IServiceCollection

The IServiceCollection to add the process enricher to.

Returns

The value of services.

Exceptions

services is null.

Applies to

.NET 10 (package-provided) und andere Versionen
Produkt Versionen
.NET 8 (package-provided), 9 (package-provided), 10 (package-provided)

AddProcessLogEnricher(IServiceCollection, IConfigurationSection)

Source:
ProcessEnricherServiceCollectionExtensions.cs

Adds an instance of the host enricher to the IServiceCollection.

C#
public static Microsoft.Extensions.DependencyInjection.IServiceCollection AddProcessLogEnricher(this Microsoft.Extensions.DependencyInjection.IServiceCollection services, Microsoft.Extensions.Configuration.IConfigurationSection section);

Parameters

services
IServiceCollection

The IServiceCollection to add the process enricher to.

section
IConfigurationSection

The IConfigurationSection to use for configuring ProcessLogEnricherOptions in the process enricher.

Returns

The value of services.

Exceptions

Any of the arguments is null.

Applies to

.NET 10 (package-provided) und andere Versionen
Produkt Versionen
.NET 8 (package-provided), 9 (package-provided), 10 (package-provided)

AddProcessLogEnricher(IServiceCollection, Action<ProcessLogEnricherOptions>)

Source:
ProcessEnricherServiceCollectionExtensions.cs

Adds an instance of the process enricher to the IServiceCollection.

C#
public static Microsoft.Extensions.DependencyInjection.IServiceCollection AddProcessLogEnricher(this Microsoft.Extensions.DependencyInjection.IServiceCollection services, Action<Microsoft.Extensions.Diagnostics.Enrichment.ProcessLogEnricherOptions> configure);

Parameters

services
IServiceCollection

The IServiceCollection to add the process enricher to.

configure
Action<ProcessLogEnricherOptions>

The ProcessLogEnricherOptions configuration delegate.

Returns

The value of services.

Exceptions

Any of the arguments is null.

Applies to

.NET 10 (package-provided) und andere Versionen
Produkt Versionen
.NET 8 (package-provided), 9 (package-provided), 10 (package-provided)