logging-log4j-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tam wei <twx...@gmail.com>
Subject log4J ClassCastException
Date Tue, 20 Dec 2005 10:11:58 GMT
Dear all,
I am using log4j 1.2.12 with jboss 4.0.2 ..... I got the following
error while i started up my jboss server ....

log4j:ERROR Could not create an Appender. Reported error follows.
[20:12:05-15:03:36,554] [ INFO:STDOUT] [JMS SessionPool Worker-3]
java.lang.ClassCastException:
com.pdcb.framework.log.JbossRollingFileZipAppender
[20:12:05-15:03:36,554] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.apache.log4j.xml.DOMConfigurator.parseAppender(DOMConfigurator.java:175)
[20:12:05-15:03:36,554] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.apache.log4j.xml.DOMConfigurator.findAppenderByName(DOMConfigurator.java:150)
[20:12:05-15:03:36,554] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.apache.log4j.xml.DOMConfigurator.findAppenderByReference(DOMConfigurator.java:163)
[20:12:05-15:03:36,554] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.apache.log4j.xml.DOMConfigurator.parseChildrenOfLoggerElement(DOMConfigurator.java:425)
[20:12:05-15:03:36,554] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.apache.log4j.xml.DOMConfigurator.parseRoot(DOMConfigurator.java:394)
[20:12:05-15:03:36,554] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.apache.log4j.xml.DOMConfigurator.parse(DOMConfigurator.java:829)
[20:12:05-15:03:36,554] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.apache.log4j.xml.DOMConfigurator.doConfigure(DOMConfigurator.java:712)
[20:12:05-15:03:36,554] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.apache.log4j.xml.DOMConfigurator.doConfigure(DOMConfigurator.java:618)
[20:12:05-15:03:36,554] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.apache.log4j.helpers.OptionConverter.selectAndConfigure(OptionConverter.java:468)
[20:12:05-15:03:36,554] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.apache.log4j.LogManager.<clinit>(LogManager.java:122)
[20:12:05-15:03:36,554] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.apache.log4j.Category.getRoot(Category.java:584)
[20:12:05-15:03:36,554] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at com.pdcb.framework.log.Log.loadConfigData(Log.java:58)
[20:12:05-15:03:36,554] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at com.pdcb.framework.log.Log.<clinit>(Log.java:48)
[20:12:05-15:03:36,554] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at com.pdcb.server.backend.helpers.Logger.log(Logger.java:32)
[20:12:05-15:03:36,554] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at com.pdcb.server.backend.init.ejb.BackendListenerMDBean.onMessage(BackendListenerMDBean.java:59)
[20:12:05-15:03:36,554] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[20:12:05-15:03:36,554] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
[20:12:05-15:03:36,554] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
[20:12:05-15:03:36,554] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at java.lang.reflect.Method.invoke(Method.java:585)
[20:12:05-15:03:36,554] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.invocation.Invocation.performCall(Invocation.java:345)
[20:12:05-15:03:36,554] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.ejb.MessageDrivenContainer$ContainerInterceptor.invoke(MessageDrivenContainer.java:475)
[20:12:05-15:03:36,554] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.resource.connectionmanager.CachedConnectionInterceptor.invoke(CachedConnectionInterceptor.java:185)
[20:12:05-15:03:36,554] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.ejb.plugins.MessageDrivenInstanceInterceptor.invoke(MessageDrivenInstanceInterceptor.java:87)
[20:12:05-15:03:36,554] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.ejb.plugins.CallValidationInterceptor.invoke(CallValidationInterceptor.java:48)
[20:12:05-15:03:36,554] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:105)
[20:12:05-15:03:36,554] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:335)
[20:12:05-15:03:36,585] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:166)
[20:12:05-15:03:36,585] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.ejb.plugins.RunAsSecurityInterceptor.invoke(RunAsSecurityInterceptor.java:94)
[20:12:05-15:03:36,585] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:192)
[20:12:05-15:03:36,585] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invoke(ProxyFactoryFinderInterceptor.java:122)
[20:12:05-15:03:36,585] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.ejb.MessageDrivenContainer.internalInvoke(MessageDrivenContainer.java:389)
[20:12:05-15:03:36,585] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.ejb.Container.invoke(Container.java:873)
[20:12:05-15:03:36,585] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.ejb.plugins.jms.JMSContainerInvoker.invoke(JMSContainerInvoker.java:1090)
[20:12:05-15:03:36,585] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.ejb.plugins.jms.JMSContainerInvoker$MessageListenerImpl.onMessage(JMSContainerInvoker.java:1392)
[20:12:05-15:03:36,585] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.jms.asf.StdServerSession.onMessage(StdServerSession.java:256)
[20:12:05-15:03:36,585] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.mq.SpyMessageConsumer.sessionConsumerProcessMessage(SpyMessageConsumer.java:904)
[20:12:05-15:03:36,585] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.mq.SpyMessageConsumer.addMessage(SpyMessageConsumer.java:160)
[20:12:05-15:03:36,585] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.mq.SpySession.run(SpySession.java:333)
[20:12:05-15:03:36,585] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.jms.asf.StdServerSession.run(StdServerSession.java:180)
[20:12:05-15:03:36,585] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(PooledExecutor.java:743)
[20:12:05-15:03:36,585] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at java.lang.Thread.run(Thread.java:595)
[20:12:05-15:03:36,585] [ INFO:STDOUT] [JMS SessionPool Worker-3]
log4j:ERROR Could not parse url
[file:/E:/GT4.0_Dev/jboss-4.0.2/server/default/conf/log4j.xml].
[20:12:05-15:03:36,585] [ INFO:STDOUT] [JMS SessionPool Worker-3]
java.lang.NullPointerException
[20:12:05-15:03:36,585] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at java.util.Hashtable.put(Hashtable.java:396)
[20:12:05-15:03:36,601]
[DEBUG:org.jboss.web.tomcat.tc5.TomcatDeployer] [main] Using session
cookies default setting
[20:12:05-15:03:36,617] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.apache.log4j.xml.DOMConfigurator.findAppenderByName(DOMConfigurator.java:151)
[20:12:05-15:03:36,617] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.apache.log4j.xml.DOMConfigurator.findAppenderByReference(DOMConfigurator.java:163)
[20:12:05-15:03:36,617] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.apache.log4j.xml.DOMConfigurator.parseChildrenOfLoggerElement(DOMConfigurator.java:425)
[20:12:05-15:03:36,617] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.apache.log4j.xml.DOMConfigurator.parseRoot(DOMConfigurator.java:394)
[20:12:05-15:03:36,617] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.apache.log4j.xml.DOMConfigurator.parse(DOMConfigurator.java:829)
[20:12:05-15:03:36,617] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.apache.log4j.xml.DOMConfigurator.doConfigure(DOMConfigurator.java:712)
[20:12:05-15:03:36,648] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.apache.log4j.xml.DOMConfigurator.doConfigure(DOMConfigurator.java:618)
[20:12:05-15:03:36,648] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.apache.log4j.helpers.OptionConverter.selectAndConfigure(OptionConverter.java:468)
[20:12:05-15:03:36,648] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.apache.log4j.LogManager.<clinit>(LogManager.java:122)
[20:12:05-15:03:36,648] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.apache.log4j.Category.getRoot(Category.java:584)
[20:12:05-15:03:36,648] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at com.pdcb.framework.log.Log.loadConfigData(Log.java:58)
[20:12:05-15:03:36,648] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at com.pdcb.framework.log.Log.<clinit>(Log.java:48)
[20:12:05-15:03:36,648] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at com.pdcb.server.backend.helpers.Logger.log(Logger.java:32)
[20:12:05-15:03:36,648] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at com.pdcb.server.backend.init.ejb.BackendListenerMDBean.onMessage(BackendListenerMDBean.java:59)
[20:12:05-15:03:36,648] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[20:12:05-15:03:36,648] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
[20:12:05-15:03:36,648] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
[20:12:05-15:03:36,648] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at java.lang.reflect.Method.invoke(Method.java:585)
[20:12:05-15:03:36,648] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.invocation.Invocation.performCall(Invocation.java:345)
[20:12:05-15:03:36,648] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.ejb.MessageDrivenContainer$ContainerInterceptor.invoke(MessageDrivenContainer.java:475)
[20:12:05-15:03:36,648] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.resource.connectionmanager.CachedConnectionInterceptor.invoke(CachedConnectionInterceptor.java:185)
[20:12:05-15:03:36,648] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.ejb.plugins.MessageDrivenInstanceInterceptor.invoke(MessageDrivenInstanceInterceptor.java:87)
[20:12:05-15:03:36,648] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.ejb.plugins.CallValidationInterceptor.invoke(CallValidationInterceptor.java:48)
[20:12:05-15:03:36,648] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:105)
[20:12:05-15:03:36,648] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:335)
[20:12:05-15:03:36,648] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:166)
[20:12:05-15:03:36,648] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.ejb.plugins.RunAsSecurityInterceptor.invoke(RunAsSecurityInterceptor.java:94)
[20:12:05-15:03:36,648] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:192)
[20:12:05-15:03:36,648] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invoke(ProxyFactoryFinderInterceptor.java:122)
[20:12:05-15:03:36,648] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.ejb.MessageDrivenContainer.internalInvoke(MessageDrivenContainer.java:389)
[20:12:05-15:03:36,648] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.ejb.Container.invoke(Container.java:873)
[20:12:05-15:03:36,664] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.ejb.plugins.jms.JMSContainerInvoker.invoke(JMSContainerInvoker.java:1090)
[20:12:05-15:03:36,664] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.ejb.plugins.jms.JMSContainerInvoker$MessageListenerImpl.onMessage(JMSContainerInvoker.java:1392)
[20:12:05-15:03:36,664] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.jms.asf.StdServerSession.onMessage(StdServerSession.java:256)
[20:12:05-15:03:36,664] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.mq.SpyMessageConsumer.sessionConsumerProcessMessage(SpyMessageConsumer.java:904)
[20:12:05-15:03:36,679] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.mq.SpyMessageConsumer.addMessage(SpyMessageConsumer.java:160)
[20:12:05-15:03:36,679] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.mq.SpySession.run(SpySession.java:333)
[20:12:05-15:03:36,679] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at org.jboss.jms.asf.StdServerSession.run(StdServerSession.java:180)
[20:12:05-15:03:36,679] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(PooledExecutor.java:743)
[20:12:05-15:03:36,679] [ INFO:STDOUT] [JMS SessionPool Worker-3]    
at java.lang.Thread.run(Thread.java:595)
[20:12:05-15:03:36,695]
[DEBUG:org.jboss.mx.loading.UnifiedClassLoader] [JMS SessionPool
Worker-3] New jmx UCL with url null


For the JbossRollingFileZipAppender.java, it extend from
RollingFileAppender.java, which will zip the log file if the number of
log files hit certain amount.

I packaged the JbossRollingFileZipAppender class into a jar file and
place under \jboss-4.0.2\server\default\lib.

log4j1.2.12.jar are put under \jboss-4.0.2\server\default\lib and my
application.ear file also contains it.

Could someone know what will be the possible reason that cause the
above exception ?

Thanks for your help
WX

---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-user-help@logging.apache.org


Mime
View raw message