title: log4j - INFO to console and ERRORS to file
body: <p>I want to redirect all messages with error level to file and messages with info level to console.
  Here is my log4j.properties: </p>
  
  <pre><code>log4j.rootLogger=INFO, stdout
  log4j.logger.java.lang.Exception=ALL, java.lang.Exception
  
  log4j.appender.stdout=org.apache.log4j.ConsoleAppender
  log4j.appender.stdout.Target=System.out
  log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
  log4j.appender.stdout.layout.ConversionPattern=%d{yyyy-MM-dd HH:mm:ss} %-5p %c{1}:%L - %m%n
  
  log4j.appender.java.lang.Exception=org.apache.log4j.RollingFileAppender
  log4j.appender.java.lang.Exception.File=\\clientexceptionlog.txt
  log4j.appender.java.lang.Exception.MaxFileSize=2048KB
  log4j.appender.java.lang.Exception.layout=org.apache.log4j.PatternLayout
  log4j.appender.java.lang.Exception.layout.ConversionPattern=%d [%t] %-5p %c - %m%n
  </code></pre>
  
  <p>But seems like it doesn't work as I expect: clientexceptionlog.txt is always empty. 
  What I'm doing wrong? Thanks!</p>