I've seen plenty of examples of using the NLog Configuration API to create multiple targets that are linked to multiple rules. However, I cannot find any documentation on how to use the NLog Configuration API to set up a wrapper target around another target. This is the configuration I'm trying to create programmatically with the API:
<targets>
<target xsi:type="BufferingWrapper"
name="InfoBufferingTarget"
bufferSize="100"
flushTimeout="60000"
slidingTimeout="true">
<target xsi:type="File"
name="InfoFileTarget"
fileName="nlog.log"
layout="${message}"
keepFileOpen="true"
openFileCacheSize="10"
bufferSize="327680"
networkWrites="true"
createDirs="true"
/>
</target>
</targets>
<rules>
<logger name="*" minlevel="Info" writeTo="InfoBufferingTarget" />
</rules>
I've got the code working with just the file target, but not exactly sure how to add the buffering wrapper.
Thanks for any help.