logging-log4j-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Himanshu Gupta" <him...@gmail.com>
Subject NullPointerException when using ErrorHandler
Date Fri, 14 Aug 2009 01:10:34 GMT
Hi Guys,

 I am using ErrorHandler in my log4j.xml file but when I put my node as:

   <appender class="com.egain.platform.util.logging.appender.RollingFileAppender" name="root">
 <errorHandler class="platform.util.logging.appender.handler.FallbackErrorHandler">
  <root-ref/><appender-ref ref="local_appender"/>
 </errorHandler>
        <param name="File" value="egpl_root_${HOST_NAME}.log"/>
        <param name="MaxFileSize" value="5MB"/>
        <param name="Threshold" value="debug"/>
        <layout class="com.egain.platform.util.logging.appender.PatternLayout">
            <param name="Pattern" value="extended"/>
        </layout>
    </appender>

 it throws a NullPointerException saying:

13 Aug 2009 18:05:26,351 <@> INFO <@> [:Finalizer] <@>  <@>  <@>
 <@>  <@> platform.util.logging.LoggingOutputStream <@> flush <@>
log4j: Finalizing appender named [V9W13_dsm-registry]. <@> 
13 Aug 2009 18:05:26,351 <@> ERROR <@> [:main] <@>  <@>  <@>
 <@>  <@> platform.util.logging.LoggingOutputStream <@> flush <@>
 at org.apache.log4j.xml.DOMConfigurator.parseErrorHandler(DOMConfigurator.java:329) <@>

13 Aug 2009 18:05:26,351 <@> ERROR <@> [:main] <@>  <@>  <@>
 <@>  <@> platform.util.logging.LoggingOutputStream <@> flush <@>
 at org.apache.log4j.xml.DOMConfigurator.parseAppender(DOMConfigurator.java:266) <@>

13 Aug 2009 18:05:26,351 <@> ERROR <@> [:main] <@>  <@>  <@>
 <@>  <@> platform.util.logging.LoggingOutputStream <@> flush <@>
 at org.apache.log4j.xml.DOMConfigurator.findAppenderByName(DOMConfigurator.java:171) <@>

13 Aug 2009 18:05:26,366 <@> ERROR <@> [:main] <@>  <@>  <@>
 <@>  <@> platform.util.logging.LoggingOutputStream <@> flush <@>
java.lang.ExceptionInInitializerError <@> 

 Can anyone please shed some light on this?

Thanks,
 Himanshu
Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message