In an effort to speed up my development process, I determined that changing the logging level, even in development made a huge difference. Keep this in mind, and let me know if you find this useful.
- December 8, 2019
I was trying to determine why my asp.net core application as so slow during startup (F5 w/debugging). I believe I found one of the reasons. By default, a new asp.net core application has an appsettings.Development.json file. Within this file there are several settings to set the default log level. Typically, you will see something like the following
{
"Logging":
{
"LogLevel":
{
"Default": "Debug",
"System": "Information",
"Microsoft": "Information"
}
}
}
Keep in mind the order of settings are as follows going from very verbose to turned off.
I found that setting my development log settings to anything above Warning improved startup up time significantly!
After I figured out above I did come across a Rick Strahl post. If you don’t follow Rick do.