serilog-extensions-hosting icon indicating copy to clipboard operation
serilog-extensions-hosting copied to clipboard

Please document that `writeToProviders` will ignore filtering rules of the .NET logging

Open AntonPetrov83 opened this issue 2 years ago • 0 comments

Hi!

I was resolving an issue that while AddAplicationInsightsLoggerProvider() sets the default filter rule to LogLevel.Warning (here) in the end it was ignored.

I used Serilog with UseSerilog() and writeToProviders: true.

As I understand this is because Serilog installs its own SerilogLoggerFactory which ignores .NET logging filters.

It is okay but please make it obvious from the readme documentation.

P.S. The same is true for Serilog.AspNetCore

AntonPetrov83 avatar Apr 07 '22 04:04 AntonPetrov83