diff --git a/aspnetcore/fundamentals/logging/index.md b/aspnetcore/fundamentals/logging/index.md index 2fd948ba86a2..59c2fcd82797 100644 --- a/aspnetcore/fundamentals/logging/index.md +++ b/aspnetcore/fundamentals/logging/index.md @@ -233,8 +233,6 @@ Calling `CreateLogger` with a fixed name can be useful when used in multiple met `ILogger` is equivalent to calling `CreateLogger` with the fully qualified type name of `T`. -***NOTE:*** [LoggerFactory.Create](/dotnet/api/microsoft.extensions.logging.loggerfactory.create) Creates a new instance of that's configured using the provided `configure` delegate. The new instance of `ILoggerFactory` creates a new logging pipeline, different from the default logging pipeline. The new logging pipeline is not configured by the `Logging` section of `appsettings.json` or `appsettings.{ENVIRONMENT}.json`. For more information, see [Logging configuration](xref:fundamentals/logging/index#configure-logging). - ## Log level @@ -879,7 +877,7 @@ The following example shows how to register filter rules in code: The logging libraries implicitly create a scope object with `SpanId`, `TraceId`, `ParentId`,`Baggage`, and `Tags`. This behavior is configured via . -[!code-csharp[](~/fundamentals/logging/index/samples/6.x/WebApp/Program.cs?name=snippet4)] +[!code-csharp[](~/fundamentals/logging/index/samples/6.x/WebLog/Program.cs?name=snippet4)] If the `traceparent` http request header is set, the `ParentId` in the log scope shows the W3C `parent-id` from in-bound `traceparent` header and the `SpanId` in the log scope shows the updated `parent-id` for the next out-bound step/span. For more information, see [Mutating the traceparent Field](https://www.w3.org/TR/trace-context/#mutating-the-traceparent-field). @@ -887,6 +885,11 @@ If the `traceparent` http request header is set, the `ParentId` in the log scope To create a custom logger, see [Implement a custom logging provider in .NET](/dotnet/core/extensions/custom-logging-provider). + + ## Additional resources * [Microsoft.Extensions.Logging source on GitHub](https://github.com/dotnet/runtime/tree/main/src/libraries/Microsoft.Extensions.Logging)