title: Logging a specific package in log4j programmatically
body: <p>I have to deploy a web app and the the log4j.properties file is created by the client so I dont have control over it.
  Their properties file is like this:</p>
  
  <pre><code>log4j.rootCategory= FILE
  
  !-----------FILE--------------!
  log4j.category.FILE=DEBUG
  log4j.appender.FILE=org.apache.log4j.RollingFileAppender
  log4j.appender.FILE.File=${catalina.base}/logs/rcweb.log
  log4j.appender.FILE.MaxFileSize=1024KB
  log4j.appender.FILE.MaxBackupIndex=10
  log4j.appender.FILE.layout=org.apache.log4j.PatternLayout
  log4j.appender.FILE.layout.ConversionPattern=%-2d{dd/MM/yyyy HH:mm:ss} [%t] %5p %c:%L - %m%n
  </code></pre>
  
  <p>And in my classes I do something like this:</p>
  
  <pre><code>private static final Logger LOG = Logger.getLogger(MaterialController.class);
  LOG.info("my log");
  </code></pre>
  
  <p>But the log file has never been created.</p>
  
  <p>I did the test and changed the <code>log4j.properties</code> file and deployed it in my computer adding the following line:</p>
  
  <pre><code>log4j.logger.br.com.golive.requisicaoCompras=DEBUG
  </code></pre>
  
  <p>This works, but I can't use the file like this.</p>
  
  <p>Are there any ideas?</p>