Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Disable logging by default in Configuration.cs #362

Merged

Conversation

eduherminio
Copy link
Member

@eduherminio eduherminio commented Aug 19, 2023

This should avoid the issue of the binary crashing without appsettings.json.
This doesn't mean it should be used without it, it will swallow all errors and arnings, but yeah, you can.

  • Add test to ensure that appsettings.json are Configuration.cs are sync'ed
  • Adjust appsettings values to Config ones

- Replace `GeneralSettings.DisableLogging` with `GeneralSettings.EnableLogging` and set it to `false` in `Configuration.cs`
- Map it manually on startup to avoid dotnet/runtime#89732
This should avoid the issue of the binary being dependent on `appsettings.json`, unless logging is required
@eduherminio eduherminio force-pushed the dissable-logging-by-default-in-source-configuration-file branch from 1dd51b6 to 461106e Compare August 19, 2023 15:57
@eduherminio eduherminio marked this pull request as ready for review August 19, 2023 18:40
@eduherminio eduherminio merged commit f1c4d0b into main Aug 19, 2023
21 checks passed
@eduherminio eduherminio deleted the dissable-logging-by-default-in-source-configuration-file branch August 19, 2023 18:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant