title: CXF logs not appending to Log file
body: <p>I want to log the Apache CXF inbound and outbound interceptors logs inside the File instead of Console</p>
  
  <p><strong>Maven project :</strong></p>
  
  <p>1) Created a file named 'org.apache.cxf.Logger' under META-INF\cxf and placed the below text</p>
  
  <p>META-INF\cxf\org.apache.cxf.Logger</p>
  
  <pre><code>       org.apache.cxf.common.logging.Log4jLogger
  </code></pre>
  
  <p><strong>2) application-context.xml:</strong>  </p>
  
  <pre><code>  &lt;cxf:bus&gt;
    &lt;cxf:inInterceptors&gt;
      &lt;ref bean="loggingInInterceptor"/&gt;
    &lt;/cxf:inInterceptors&gt;
    &lt;cxf:outInterceptors&gt;
      &lt;ref bean="loggingOutInterceptor"/&gt;
     &lt;/cxf:outInterceptors&gt;
    &lt;cxf:outFaultInterceptors&gt;
      &lt;ref bean="loggingOutInterceptor"/&gt;
    &lt;/cxf:outFaultInterceptors&gt;
    &lt;cxf:inFaultInterceptors&gt;
      &lt;ref bean="loggingInInterceptor"/&gt;
    &lt;/cxf:inFaultInterceptors&gt;
    &lt;/cxf:bus&gt;  
  &lt;jaxrs:server id="services" address="/mysvc"&gt;   
      &lt;jaxrs:serviceBeans&gt;
          &lt;ref bean="myserviceImpl" /&gt;
      &lt;/jaxrs:serviceBeans&gt;
      &lt;jaxrs:providers&gt;
          &lt;bean class="com.fasterxml.jackson.jaxrs.json.JacksonJsonProvider" /&gt;
      &lt;/jaxrs:providers&gt;
       &lt;jaxrs:outInterceptors&gt;
          &lt;ref bean="loggingOutInterceptor" /&gt;
      &lt;/jaxrs:outInterceptors&gt;
      &lt;jaxrs:inInterceptors&gt;
          &lt;ref bean="loggingInInterceptor" /&gt;
      &lt;/jaxrs:inInterceptors&gt;     
    &lt;/jaxrs:server&gt;
    &lt;bean class="org.apache.cxf.interceptor.LoggingInInterceptor" id="loggingInInterceptor" /&gt;
    &lt;bean class="org.apache.cxf.interceptor.LoggingOutInterceptor" id="loggingOutInterceptor" /&gt;
  </code></pre>
  
  <p><strong>3)  log4j2.xml: under src\main\resources folder</strong></p>
  
  <pre><code>   &lt;?xml version="1.0" encoding="UTF-8"?&gt;
       &lt;Configuration status="warn" name="CompanyServices" packages=""&gt;
      &lt;Appenders&gt;
      &lt;RollingFile name="RollingFile" fileName="D:/temp/companyfile.log"
          filePattern="companyfile-%d{MM-dd-yyyy}-%i.log.gz"&gt;
          &lt;PatternLayout&gt;
              &lt;Pattern&gt;%d %p [%t] %C:%L - %m%n&lt;/Pattern&gt;
          &lt;/PatternLayout&gt;
          &lt;Policies&gt;
              &lt;SizeBasedTriggeringPolicy size="10 MB" /&gt;
          &lt;/Policies&gt;
      &lt;/RollingFile&gt;
      &lt;Console name="STDOUT" target="SYSTEM_OUT"&gt;
          &lt;PatternLayout&gt;
              &lt;Pattern&gt;%d %p [%t] %C:%L - %m%n&lt;/Pattern&gt;
          &lt;/PatternLayout&gt;
      &lt;/Console&gt;
     &lt;/Appenders&gt;
     &lt;Loggers&gt;
      &lt;Logger name="com.myorg.mycompany" level="trace"
          additivity="false"&gt;
          &lt;AppenderRef ref="RollingFile" /&gt;
      &lt;/Logger&gt;
      &lt;Logger name="org.apache.cxf.interceptor" level="info" 
          additivity="false"&gt;
          &lt;AppenderRef ref="RollingFile" /&gt;
      &lt;/Logger&gt;
      &lt;Root level="all"&gt;
          &lt;AppenderRef ref="RollingFile" /&gt;
          &lt;/Root&gt;
        &lt;/Loggers&gt;
     &lt;/Configuration&gt;
  </code></pre>
  
  <p><strong>4. pom.xml :</strong></p>
  
  <pre><code>    &lt;dependency&gt;
          &lt;groupId&gt;org.apache.cxf&lt;/groupId&gt;
          &lt;artifactId&gt;cxf-rt-frontend-jaxrs&lt;/artifactId&gt;
          &lt;version&gt;${cxf.version}&lt;/version&gt;
      &lt;/dependency&gt;
      &lt;dependency&gt;
          &lt;groupId&gt;org.apache.cxf&lt;/groupId&gt;
          &lt;artifactId&gt;cxf-rt-rs-client&lt;/artifactId&gt;
          &lt;version&gt;${cxf.version}&lt;/version&gt;
      &lt;/dependency&gt;
      &lt;dependency&gt;
          &lt;groupId&gt;org.apache.cxf&lt;/groupId&gt;
          &lt;artifactId&gt;cxf-rt-rs-service-description&lt;/artifactId&gt;
          &lt;version&gt;${cxf.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;${log4j2.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;${log4j2.version}&lt;/version&gt;
      &lt;/dependency&gt;
  </code></pre>
  
  <p>A file was getting generated and printing only my application level logs to my file. But not printing CXF interceptors logs in to the file.</p>
  
  <p>Please suggest what's going wrong?</p>