How do I implement a custom LOG4NET parser for my XML file. My XML file contains:
(1) extra attributes on the appender element (2) custom replacements on the elements of some of the appenders that need to be set at runtime.For example:
<appender name=... type=... mode="something">
<some-property-of-appender>${MyValueForThisPropertyFromDB}</some-property-of-appender>
</appender>
I have read that I am supposed to imple开发者_如何学Goment a Custom Repository probably using the LoggerRepositorySkeleton but not sure how to put this whole thing together. Any suggestions?
Since you are trying to initialize most of the log4net configuration from database the easiest way would be to configure log4net from code. Then you will have full control over what parameter values you use and where they come from.
精彩评论