title: Logs in two different files log4Net
body: <p>I wanted to write logs in two different files using log4net, one in the global log file while the other for particular user file, for this I set the param in appender like this</p>
  
  <pre><code>&lt;param name="File" value="D:\Projects\Web\Web\Services\Log\%property{LogFileName}" /&gt;
  </code></pre>
  
  <p>And defined a function like this </p>
  
  <pre><code>public void AddInfo(string message)
  {
      log4net.GlobalContext.Properties["LogFileName"] = this.UserId + ".txt";
      log4net.Config.XmlConfigurator.Configure();
      Logger.Info(message);
  
      log4net.GlobalContext.Properties["LogFileName"] = "ServiceLog.txt";
      log4net.Config.XmlConfigurator.Configure();
      Logger.Info(message);        
  }
  </code></pre>
  
  <p>This all is working find, every log is written in two different files successfully.</p>
  
  <p>My concern is, is the approach correct if we think about performance?</p>
  
  <p>For each and every log it will configure log4net two times, will it affect performance negatively?</p>