[jboss-user] [JBoss Seam] - log4j error in Tomcat 6

tptackab do-not-reply at jboss.com
Tue Jun 26 20:05:06 EDT 2007


I'm seeing this NullPointer error when I shutdown Tomcat 6.0.13:

INFO: Stopping service Catalina
  | Jun 26, 2007 4:49:57 PM org.apache.catalina.core.ApplicationContext log
  | INFO: SessionListener: contextDestroyed()
  | Jun 26, 2007 4:49:57 PM org.apache.catalina.core.ApplicationContext log
  | INFO: ContextListener: contextDestroyed()
  | ContextListener: attributeRemoved('com.sun.faces.config.WebConfiguration', 'com.sun.faces.config.WebConfiguration at 1aadcc6')
  | 16:49:57,541 INFO  [SessionFactoryImpl] closing
  | Failed to initalize plugin: org.jboss.logging.Log4jLoggerPlugin at c9d448
  | Failed to initalize plugin: org.jboss.logging.Log4jLoggerPlugin at ba3671
  | Jun 26, 2007 4:49:57 PM org.apache.coyote.http11.Http11Protocol destroy
  | INFO: Stopping Coyote HTTP/1.1 on http-8080
  | Exception in thread "Thread-2" java.lang.NullPointerException
  | 	at org.apache.log4j.helpers.PatternConverter.spacePad(PatternConverter.java:98)
  | 	at org.apache.log4j.helpers.PatternConverter.format(PatternConverter.java:71)
  | 	at org.apache.log4j.PatternLayout.format(PatternLayout.java:495)
  | 	at org.apache.log4j.WriterAppender.subAppend(WriterAppender.java:292)
  | 	at org.apache.log4j.WriterAppender.append(WriterAppender.java:150)
  | 	at org.apache.log4j.AppenderSkeleton.doAppend(AppenderSkeleton.java:221)
  | 	at org.apache.log4j.helpers.AppenderAttachableImpl.appendLoopOnAppenders(AppenderAttachableImpl.java:57)
  | 	at org.apache.log4j.Category.callAppenders(Category.java:187)
  | 	at org.apache.log4j.Category.forcedLog(Category.java:372)
  | 	at org.apache.log4j.Category.log(Category.java:864)
  | 	at org.jboss.logging.Log4jLoggerPlugin.info(Log4jLoggerPlugin.java:160)
  | 	at org.jboss.logging.Logger.info(Logger.java:187)
  | 	at org.jboss.kernel.plugins.bootstrap.standalone.StandaloneBootstrap$Shutdown.run(StandaloneBootstrap.java:123)

I'm using the following log4j config file just as I found it in the JPA (tomcat pojo) example in Seam 1.3.0 ALPHA:

<?xml version="1.0" encoding="UTF-8"?>
  | <!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
  | 
  | <!-- ===================================================================== -->
  | <!--                                                                       -->
  | <!--  Log4j Configuration                                                  -->
  | <!--                                                                       -->
  | <!-- ===================================================================== -->
  | 
  | <!-- $Id: log4j.xml,v 1.1 2006/11/08 09:38:58 myuan Exp $ -->
  | 
  | <!--
  |    | For more configuration infromation and examples see the Jakarta Log4j
  |    | owebsite: http://jakarta.apache.org/log4j
  |  -->
  | 
  | <log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/" debug="false">
  |    
  |    <appender name="CONSOLE" class="org.apache.log4j.ConsoleAppender">
  |       <errorHandler class="org.jboss.logging.util.OnlyOnceErrorHandler"/>
  |       <param name="Target" value="System.out"/>
  | 
  |       <layout class="org.apache.log4j.PatternLayout">
  |          <param name="ConversionPattern" value="%d{HH:mm:ss,SSS} %-5p [%c{1}] %m%n"/>
  |       </layout>
  |    </appender>
  |    
  |    <!-- 
  |    <category name="org.hibernate">
  |       <priority value="DEBUG"/>
  |    </category>
  |    -->
  | 
  |    <!-- 
  |    <category name="org.jboss.seam">
  |       <priority value="DEBUG"/>
  |    </category>
  |    -->
  |    
  |    <!-- 
  |    <category name="org.jboss.kernel">
  |       <priority value="DEBUG"/>
  |    </category>
  |    -->
  | 
  |    <root>
  |       <priority value="INFO"/>
  |       <appender-ref ref="CONSOLE"/>
  |    </root>
  | 
  | </log4j:configuration>
  | 

I'm using the exact same library set from the JPA example except the two el-*.jar libs (wouldn't run with those in place).

The application seems to work fine, it's just the exception on shutdown makes me nervous. 

Is this an indication of trouble elsewhere? Any suggestions on how to make it go away would be very much appreciated.

Thanks!

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4057920#4057920

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4057920



More information about the jboss-user mailing list