<?xml version="1.0"?>
<log4net>
  <appender name="Console" type="log4net.Appender.TraceAppender">
    <layout type="log4net.Layout.PatternLayout">
      <!-- Pattern to output the caller's file name and line number -->
      <conversionPattern value="%5level [%thread] (%file:%line): %message%newline" />
    </layout>
  </appender>

  <appender name="RollingFile" type="log4net.Appender.RollingFileAppender">
    <file type="log4net.Util.PatternString" value="%envFolderPath{LocalApplicationData}\\Arma 3 Launcher\\Logs\\Launcher.log" />
    <encoding value="utf-8" />
    <appendToFile value="true" />
    <maxSizeRollBackups value="1" />
    <staticLogFileName value="true" />
    <rollingStyle value="Size" />
    <preserveLogFileNameExtension value="true" />
    <layout type="log4net.Layout.PatternLayout">
      <header value="%newline%newline[BEGIN LOGGING AT %date]%newline" type="log4net.Util.PatternString" />
      <conversionPattern value="%date [%5.5level] %3.3thread: %logger: %message%newline" />
      <!--<conversionPattern value="%date [%5.5level] %3.3thread: %logger [%type.%method:%line] %message%newline" />-->
    </layout>
    <filter type="log4net.Filter.LoggerMatchFilter">
      <loggerToMatch value="FileSynchronization" />
      <acceptOnMatch value="false" />
    </filter>
    <filter type="log4net.Filter.LoggerMatchFilter">
      <loggerToMatch value="SteamLayer" />
      <acceptOnMatch value="false" />
    </filter>
    <filter type="log4net.Filter.LoggerMatchFilter">
      <loggerToMatch value="SteamApi" />
      <acceptOnMatch value="false" />
    </filter>
    <filter type="log4net.Filter.LoggerMatchFilter">
      <loggerToMatch value="SteamAPIWrapDump" />
      <acceptOnMatch value="false" />
    </filter>
    <!--<filter type="log4net.Filter.LoggerMatchFilter">
      <loggerToMatch value="SteamExtensionStorage" />
      <acceptOnMatch value="false" />
    </filter>-->
  </appender>
 
  <!--
  <appender name="SteamExtensionStorageFile" type="log4net.Appender.RollingFileAppender">
    <file type="log4net.Util.PatternString" value="%envFolderPath{LocalApplicationData}\\Arma 3 Launcher\\Logs\\ExtensionStorage.Steam.log" />
    <encoding value="utf-8" />
    <appendToFile value="true" />
    <maxSizeRollBackups value="1" />
    <layout type="log4net.Layout.PatternLayout">
      <conversionPattern value="%date [%5.5level]   %3.3thread   %logger: %message%newline" />
    </layout>
  </appender>
  -->

  <appender name="FileSyncFile" type="log4net.Appender.RollingFileAppender">
    <file type="log4net.Util.PatternString" value="%envFolderPath{LocalApplicationData}\\Arma 3 Launcher\\Logs\\FileSync.log" />
    <encoding value="utf-8" />
    <appendToFile value="true" />
    <maxSizeRollBackups value="1" />
    <staticLogFileName value="true" />
    <rollingStyle value="Size" />
    <preserveLogFileNameExtension value="true" />
    <layout type="log4net.Layout.PatternLayout">
      <header value="%newline%newline[BEGIN LOGGING AT %date]%newline" type="log4net.Util.PatternString" />
      <conversionPattern value="%date [%5.5level]   %3.3thread   %logger: %message%newline" />
    </layout>
  </appender>

  <appender name="SteamFile" type="log4net.Appender.RollingFileAppender">
    <file type="log4net.Util.PatternString" value="%envFolderPath{LocalApplicationData}\\Arma 3 Launcher\\Logs\\Steam.Native.log" />
    <encoding value="utf-8" />
    <appendToFile value="true" />
    <maxSizeRollBackups value="1" />
    <staticLogFileName value="true" />
    <rollingStyle value="Size" />
    <preserveLogFileNameExtension value="true" />
    <layout type="log4net.Layout.PatternLayout">
      <header value="%newline%newline[BEGIN LOGGING AT %date]%newline" type="log4net.Util.PatternString" />
      <conversionPattern value="%date [%5.5level]   %3.3thread   %logger: %message%newline" />
    </layout>
  </appender>

  <appender name="SteamAPIWrap" type="log4net.Appender.RollingFileAppender">
    <file type="log4net.Util.PatternString" value="%envFolderPath{LocalApplicationData}\\Arma 3 Launcher\\Logs\\Steam.Wrap.log" />
    <encoding value="utf-8" />
    <appendToFile value="true" />
    <maxSizeRollBackups value="1" />
    <staticLogFileName value="true" />
    <rollingStyle value="Size" />
    <preserveLogFileNameExtension value="true" />
    <layout type="log4net.Layout.PatternLayout">
      <header value="%newline%newline[BEGIN LOGGING AT %date]%newline" type="log4net.Util.PatternString" />
      <conversionPattern value="%date [%5.5level]   %3.3thread   %logger: %message%newline" />
    </layout>
  </appender>
  
  <appender name="ServerBrowserServiceFile" type="log4net.Appender.RollingFileAppender">
    <file type="log4net.Util.PatternString" value="%envFolderPath{LocalApplicationData}\\Arma 3 Launcher\\Logs\\ServerBrowser.Service.log" />
    <encoding value="utf-8" />
    <appendToFile value="true" />
    <maxSizeRollBackups value="1" />
    <staticLogFileName value="true" />
    <rollingStyle value="Size" />
    <preserveLogFileNameExtension value="true" />
    <layout type="log4net.Layout.PatternLayout">
      <header value="%newline%newline[BEGIN LOGGING AT %date]%newline" type="log4net.Util.PatternString" />
      <conversionPattern value="%date [%5.5level]   %3.3thread   %logger: %message%newline" />
    </layout>
  </appender>


  <root>
    <level value="INFO" />
    <!--<appender-ref ref="Console" />-->
    <appender-ref ref="RollingFile" />
  </root>
  <logger name="Launcher">
    <level value="INFO" />
  </logger>
  <logger name="SharedResources">
    <level value="INFO" />
  </logger>
  <logger name="Utils">
    <level value="INFO" />
  </logger>
  <logger name="SteamApi">
    <level value="WARN" />
    <appender-ref ref="SteamFile" />
  </logger>
  <logger name="SteamLayer" additive="False">
    <level value="WARN" />
    <appender-ref ref="SteamFile" />
  </logger>
  <logger name="SteamAPIWrap">
    <level value="WARN" />
    <appender-ref ref="SteamAPIWrap" />
  </logger>
  <logger name="SteamAPIWrapDump">
    <level value="WARN" />
  </logger>
  <logger name="SteamManager.Publisher">
    <level value="WARN" />
  </logger>
  <logger name="LockLogger">
    <level value="OFF" />
  </logger>
  <logger name="Stopwatch">
    <level value="OFF" />
  </logger>
  <logger name="FileSynchronization">
    <level value="ALL" />
    <appender-ref ref="FileSyncFile" />
  </logger>
  <logger name="ServerBrowser.Service">
    <level value="INFO" />
    <appender-ref ref="ServerBrowserServiceFile" />
  </logger>
  <logger name="SteamExtensionStorage">
    <level value="INFO" />
    <appender-ref ref="SteamExtensionStorageFile" />
  </logger>
</log4net>