-
Notifications
You must be signed in to change notification settings - Fork 10.4k
Open
Labels
area-middlewareIncludes: URL rewrite, redirect, response cache/compression, session, and other general middlewaresIncludes: URL rewrite, redirect, response cache/compression, session, and other general middlewaresfeature-diagnosticsDiagnostic middleware and pages (except EF diagnostics)Diagnostic middleware and pages (except EF diagnostics)feature-http-logging
Milestone
Description
In production i want to log each http request in the format I select. With HttpLogging I can selected Headers and LoggingFields but I cannot format the result, which looks something like this.
I need to be able create single line logs and reorder logged properties
Describe the solution you'd like
In HttpLoggingOptions
I would like to be able to specify string format. It would look something like this:
builder.Services.AddHttpLogging(options =>
{
options.LogFormat = "Protocol {HttpProtocol} Scheme: {RequestScheme} \n Path: {Path}";
});
Additional context
No response
rafal-marciniak, alrethomas, kalimuthuswamy, julio-gorge, levanvunam and 43 more
Metadata
Metadata
Assignees
Labels
area-middlewareIncludes: URL rewrite, redirect, response cache/compression, session, and other general middlewaresIncludes: URL rewrite, redirect, response cache/compression, session, and other general middlewaresfeature-diagnosticsDiagnostic middleware and pages (except EF diagnostics)Diagnostic middleware and pages (except EF diagnostics)feature-http-logging