title: Log4j2, no logs in file
body: <p>I am trying to configure log4j2 within a maven project without a standard structure, but even though the file is created nothing is appended.</p>
  
  <p>I have the following dependencies in the pom.xml </p>
  
  <pre><code>    &lt;dependency&gt;
          &lt;groupId&gt;org.slf4j&lt;/groupId&gt;
          &lt;artifactId&gt;slf4j-api&lt;/artifactId&gt;
          &lt;version&gt;${slf4j-version}&lt;/version&gt;
      &lt;/dependency&gt;
  
      &lt;dependency&gt;
          &lt;groupId&gt;org.apache.logging.log4j&lt;/groupId&gt;
          &lt;artifactId&gt;log4j-slf4j-impl&lt;/artifactId&gt;
          &lt;version&gt;${log4j-version}&lt;/version&gt;
      &lt;/dependency&gt;
  
      &lt;dependency&gt;
          &lt;groupId&gt;org.apache.logging.log4j&lt;/groupId&gt;
          &lt;artifactId&gt;log4j-api&lt;/artifactId&gt;
          &lt;version&gt;${log4j-version}&lt;/version&gt;
      &lt;/dependency&gt;
  
      &lt;dependency&gt;
          &lt;groupId&gt;org.apache.logging.log4j&lt;/groupId&gt;
          &lt;artifactId&gt;log4j-core&lt;/artifactId&gt;
          &lt;version&gt;${log4j-version}&lt;/version&gt;
      &lt;/dependency&gt;
  
      &lt;dependency&gt;
          &lt;groupId&gt;com.fasterxml.jackson.core&lt;/groupId&gt;
          &lt;artifactId&gt;jackson-core&lt;/artifactId&gt;
          &lt;version&gt;${jackson-version}&lt;/version&gt;
      &lt;/dependency&gt;
  
      &lt;dependency&gt;
          &lt;groupId&gt;com.fasterxml.jackson.core&lt;/groupId&gt;
          &lt;artifactId&gt;jackson-databind&lt;/artifactId&gt;
          &lt;version&gt;${jackson-version}&lt;/version&gt;
      &lt;/dependency&gt;
  </code></pre>
  
  <p>I am using the following versions</p>
  
  <pre><code>    &lt;properties&gt;
          &lt;slf4j-version&gt;1.7.21&lt;/slf4j-version&gt;
          &lt;log4j-version&gt;2.6.2&lt;/log4j-version&gt;
          &lt;jackson-version&gt;2.8.2&lt;/jackson-version&gt;
      &lt;/properties&gt;
  </code></pre>
  
  <p>and the following log4j2.properties </p>
  
  <pre><code>status = info
  rootLogger.level = info
  
  name = PropertiesConfig
  property.fileName = ./log/log.txt
  
  appender.rolling.type = RollingFile
  appender.rolling.name = RollingFile
  appender.rolling.fileName = ${fileName}
  appender.rolling.filePattern = ./log/log_%d{dd-MM-yy}.txt
  appender.rolling.append = true
  
  appender.rolling.layout.type = JSONLayout
  appender.rolling.layout.complete = true
  
  appender.rolling.policies.type = Policies
  appender.rolling.policies.time.type = TimeBasedTriggeringPolicy
  appender.rolling.policies.time.interval = 1
  appender.rolling.policies.time.modulate = true
  
  appender.rolling.strategy.type = DefaultRolloverStrategy
  appender.rolling.strategy.max = 5
  </code></pre>
  
  <p>Also, because of the project's structure I am setting the property file like this</p>
  
  <pre><code>    LoggerContext context = (LoggerContext) LogManager.getContext(false);
      File file = new File(CONFIGURATION_DIR + File.separator + "log4j2.properties");
  
      // this will force a reconfiguration
      context.setConfigLocation(file.toURI());
  </code></pre>
  
  <p>Even though the file gets created nothing is appended to the file and I have no errors. Am I missing something, or doing something wrong ?</p>