You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Description
When writing logs using the ILogger<T> API from M.E.L.A v6.0.0, Serilog does not detect any log parameters. Works as expected after downgrading to v5.0.0
using Microsoft.Extensions.Logging;
...
private readonly ILogger<MyClass> _logger;
...
_logger.LogInformation("The value is {Value}", value);
Expected behaviour
The console should display the log with the usual colour coding.
Note: it does display the log, but without the colour coding.
App Insights should contain the log with custom dimensions 'Value' = "[the-value]" and 'MessageTemplate' = "The value is {Value}"
Note: it does contain the log, but the 'Value' custom dimension is not included, and the 'MessageTemplate' contains the resolved string i.e. "The value is [the-value]"
Relevant package, tooling and runtime versions
net5.0
Serilog.AspNetCore 5.0.0
Serilog.Sinks.ApplicationInsights 3.1.0
The text was updated successfully, but these errors were encountered:
Thanks for taking the time to let us know. Would it be possible to assemble a reproduction, ideally using only the Console sink and CompactJsonFormatter() or JsonFormatter(), that demonstrates the issue? (If not, this may be a Serilog.Sinks.ApplicationInsights problem, and would need to be transferred to/dealt with in that repository).
Same here. I just upgraded a .NET Core 3.1 project to .NET 6 using Serilog.AspNetCore 6.0.1 and Serilog.Sinks.Splunk 3.7.0.
Same observations: Console output is not colored anymore and message properties in Splunk are missing.
I'll try to provide you a sample project.
Edit: While creating the sample project I realized that this problem only occurs if I add the Steeltoe.Extensions.Logging.DynamicSerilogBase NuGet package. I will file an issue in their repository.
Description
When writing logs using the
ILogger<T>
API from M.E.L.A v6.0.0, Serilog does not detect any log parameters. Works as expected after downgrading to v5.0.0Reproduction
Serilog configured with:
Logs written as:
Expected behaviour
Relevant package, tooling and runtime versions
The text was updated successfully, but these errors were encountered: