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

Configuration via appsettings.json #52

Open
lowkay opened this issue Aug 6, 2021 · 0 comments
Open

Configuration via appsettings.json #52

lowkay opened this issue Aug 6, 2021 · 0 comments

Comments

@lowkay
Copy link

lowkay commented Aug 6, 2021

Howdy,

Firstly, I'm using the 4.0.0-beta3 release as I understand the 3.x releases have a critical bug.

I have tried to follow the readme to configure the sink via appsettings.json, however I receive the following error:

"Unable to find a method called LokiHttp for supplied arguments: labels, serverUrl. Candidate methods are:
LokiHttp(configFactory)"

I attribute this to a pull request that removed the logging configuration extension overloads and replaced them with a single argument. However, I cannot figure out whether it's even possible to leverage this argument from appsettings.json as Serilog complains it cannot instantiate a Func.

I have worked around this issue by adding my own extension method, however, I would like to bring it to your attention as it breaks for anybody using the existing configuration file approach.

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

No branches or pull requests

1 participant