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
https://docs.microsoft.com/en-us/dotnet/core/extensions/logging?tabs=command-line#configure-logging explains how to configure logging for .NET Core applications using appsettings.json, but obviously that file isn't relevant for .NET Framework apps that use app.config. I'm trying to see debug logs that my application is emitting, but since the default log level is info, these entries never appear. I've tried adding various elements to my app.config to mimic what's in appsettings.json but so far haven't found something that works; the only thing that does is calling ILoggingBuilder.SetMinimumLevel(LogLevel.Debug) in the service container construction, but of course that is not runtime-configurable.
Is this even possible in ye olde Framework land? If so and you've done it yourself (without using a third-party logging framework and/or reinventing the wheel), please share the details!
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
https://docs.microsoft.com/en-us/dotnet/core/extensions/logging?tabs=command-line#configure-logging explains how to configure logging for .NET Core applications using
appsettings.json
, but obviously that file isn't relevant for .NET Framework apps that useapp.config
. I'm trying to see debug logs that my application is emitting, but since the default log level is info, these entries never appear. I've tried adding various elements to myapp.config
to mimic what's inappsettings.json
but so far haven't found something that works; the only thing that does is callingILoggingBuilder.SetMinimumLevel(LogLevel.Debug)
in the service container construction, but of course that is not runtime-configurable.Is this even possible in ye olde Framework land? If so and you've done it yourself (without using a third-party logging framework and/or reinventing the wheel), please share the details!
Beta Was this translation helpful? Give feedback.
All reactions