-
Notifications
You must be signed in to change notification settings - Fork 17
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
ByExcluding filtering saved in appsettings.json #125
Comments
For usage questions like this, best to log them on stackoverflow, post a link here and close - this tracker is for bugs with repros and/or detailed feature requests. |
Hello, I have discovered new details about my case. I finally found the correct expression that filters the exception. It is also crucial where the "filter" section is located—it must be applied globally for it to work. With the following settings, everything works fine.
However, I wanted to filter only the Sentry sink, so I added the filter section as shown below.
Is it possible to use the Filter section at the specific sink and saved this in appsettings.json? |
My answer remains unchanged, post your full question on SO and post a link here |
May I ask which version of serilog are you using? Newest version seems to ignore "Filter". I may have to downgrade. I am running across the same (bug) as well. Filter must be at global level, not sink level, which is weird at best. |
Same Issue here. |
Filtering at the sink level is implemented via |
Hello community,
I'm not sure if this is a bug, but I can't figure out why it's not working.
I'm trying to create a PoC where NotImplementedException is filtered out and not logged.
When I apply the ByExcluding filter directly in code, it works as expected. However, it doesn't work when the settings are loaded from appsettings.json.
Reproduction
Here is sample of Asp.NET Web API project:
Throwing exception:
The question is - how to exclude a specific exception in appsettings?
The text was updated successfully, but these errors were encountered: