SerilogAnalyzer | based analysis for code | Code Analyzer library
kandi X-RAY | SerilogAnalyzer Summary
kandi X-RAY | SerilogAnalyzer Summary
Roslyn-based analysis for code using the Serilog logging library. Checks for common mistakes and usage problems.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of SerilogAnalyzer
SerilogAnalyzer Key Features
SerilogAnalyzer Examples and Code Snippets
Community Discussions
Trending Discussions on SerilogAnalyzer
QUESTION
I am trying to setup Serilog in a CMS that has some default logging configuration setup that we define as the CMS, however allowing developers using the CMS to extend and configure there own logging requirements by using the Serilog AppSettings Nuget package - https://github.com/serilog/serilog-settings-appsettings
I have some of this working and able to configure other Sinks in an external configuration file the problem I have and need help with, is how do I let developers configure a file sink to generate a txt logile that only includes their namespace?
With a C# class I know I can create a sub-logger and then use a Filter like so
.Filter.ByIncludingOnly(Matching.FromSource("DevelopersNamespace"))
but using the Serilog Analyzer VS Extension - https://github.com/Suchiman/SerilogAnalyzer it cannot generate an example XML AppSettings configuration.
Here is a copy of my Logger Configuration in C#
...ANSWER
Answered 2018-Aug-13 at 17:09For anyone interested or was to come across this post at a later date this is how I solved it.
I used two configuration files one to configure the main logging pipeline and a user config for a sub-logger that they can then use filtering if required without effecting the main logging pipeline.
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install SerilogAnalyzer
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page