0 Replies Latest reply on Apr 27, 2012 7:23 AM by maxdib

    AS7 Logging

    maxdib

      Hi All,

      I know the AS7 logging issue has been discussed at length in this forum. But even after following the recommendations provided by the experts i am faced with the same issue where the application logs are still going to the server.log of AS7.

       

      i have two spring applications (2 war files) deployed in a single JBOSS AS7 instance running in standalone mode.

      And i have changed the jboss-deployment-structure.xml as below

       

      <jboss-deployment-structure>

      <!--<ear-subdeployments-isolated>false</ear-subdeployments-isolated>-->

         <deployment name="Test.war">

          <exclusions >

             <module name="org.apache.log4j" />

          </exclusions>

         </deployment>

      </jboss-deployment-structure>

       

      for both the applications.

       

      Also, i have put the log4j.properties of both the application war files in the their respective /WEB-INF/lib directory (as suggested in various other posts).

      The contents of my log4j.properties file is as below: Similar configuration of log4j.properties for the other application.

      But, when I start up the application both the application logs are written to the jboss server.log

      ------------------------------------------------------------------------------------------------------------------------------------------------

      log4j.logger.com.test=DEBUG,logfile

      log4j.logger.com.test.autopassj=DEBUG,autopasslogfile

      log4j.appender.logfile=org.apache.log4j.RollingFileAppender

      log4j.appender.logfile.File=../standalone/log/X.log

      log4j.appender.logfile.MaxBackupIndex=20

      log4j.appender.logfile.MaxFileSize=5MB

      log4j.appender.logfile.Encoding=UTF-8

      log4j.appender.logfile.layout.ConversionPattern=%d %p [%c: %M: %L] - %m%n

      log4j.appender.logfile.layout=org.apache.log4j.PatternLayout

       

       

      # Autopass Log

       

      log4j.appender.autopasslogfile.MaxBackupIndex=5

      log4j.appender.autopasslogfile.MaxFileSize=5MB

      log4j.appender.autopasslogfile.Encoding=UTF-8

      log4j.appender.autopasslogfile.File=../standalone/log/AppLog.log

      log4j.appender.autopasslogfile.layout.ConversionPattern=%d %p [%c: %M: %L] - %m%n

      log4j.appender.autopasslogfile.layout=org.apache.log4j.PatternLayout

      log4j.appender.autopasslogfile=org.apache.log4j.RollingFileAppender

       

       

      # Spring Framework Log

      log4j.logger.org.springframework=INFO,springLogfile

      log4j.appender.springLogfile.File=../standalone/log/SpringFramework.log

      log4j.appender.springLogfile.MaxBackupIndex=20

      log4j.appender.springLogfile.MaxFileSize=5MB

      log4j.appender.springLogfile.Encoding=UTF-8

      log4j.appender.springLogfile.layout.ConversionPattern=%d %p [%c] - %m%n

      log4j.appender.springLogfile.layout=org.apache.log4j.PatternLayout

      log4j.appender.springLogfile=org.apache.log4j.RollingFileAppender

       

      ------------------------------------------------------------------------------------------------------------------------------------------------

       

      Please any help in this direction will be really appreciated.

       

      Thanks and Regards.