Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>I don't know if there is a more automatic way to get each AppDomain to use the same config information, but you might be able to use the technique in this post:</p> <p><a href="https://stackoverflow.com/questions/4091606/most-useful-nlog-configurations/4260142#4260142">Most useful NLog configurations</a></p> <p>To set the configuration programmatically via XML. For each AppDomain you load, you could read the NLog config file and then set the XML on NLog in the new AppDomain. </p> <p>One possible solution for getting your global values to the new AppDomain would be to store them using CallContext.LogicalSetData. The values will flow to the new AppDomain. Write a custom LayoutRenderer to get the values using CallContext.LogicalGetData. The LayoutRenderer is pretty easy to write. </p> <p>See this post for an example of how to write a custom LayoutRenderer that looks up a value based on a key (just like the GDC). For the internals, just use CallContext.LogicalGetData to retrieve the value:</p> <p><a href="https://stackoverflow.com/questions/3961815/custom-log4net-property-patternlayoutconverter-with-index">Custom log4net property PatternLayoutConverter (with index)</a></p> <p>See this blog post by Jeffrey Richter about using the CallContext:</p> <p><a href="http://www.wintellect.com/CS/blogs/jeffreyr/archive/2010/09/27/logical-call-context-flowing-data-across-threads-appdomains-and-processes.aspx" rel="nofollow noreferrer">http://www.wintellect.com/CS/blogs/jeffreyr/archive/2010/09/27/logical-call-context-flowing-data-across-threads-appdomains-and-processes.aspx</a></p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload