java.lang.NullPointerException

QOS.ch JIRA | Mike Youngstrom | 7 years ago
  1. 0

    We're using jcl-over-slf4j. When we Serialize an instance of SLF4JLocationAwareLog any subsequent calls to SLF4JLocationAwareLog throw a NPE. Would it be possible to improve the Serialization implementation of SLF4JLocationAwareLog either retrieve the LocationAwareLogger on readResolve() or simply check for a null logger instead of throwing an NPE? The following is a stacktrace I get when using jcl-over-slf4j with Spring: [7/28/09 0:14:32:226 MDT] 0000005a SystemErr R java.lang.NullPointerException [7/28/09 0:14:32:226 MDT] 0000005a SystemErr R at org.apache.commons.logging.impl.SLF4JLocationAwareLog.isDebugEnabled(SLF4JLocationAwareLog.java:59) [7/28/09 0:14:32:226 MDT] 0000005a SystemErr R at org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor.buildLifecycleMetadata(InitDestroyAnnotationBeanPostProcessor.java:201) [7/28/09 0:14:32:226 MDT] 0000005a SystemErr R at org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor.findLifecycleMetadata(InitDestroyAnnotationBeanPostProcessor.java:182) [7/28/09 0:14:32:227 MDT] 0000005a SystemErr R at org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor.postProcessBeforeDestruction(InitDestroyAnnotationBeanPostProcessor.java:160) [7/28/09 0:14:32:227 MDT] 0000005a SystemErr R at org.springframework.beans.factory.support.DisposableBeanAdapter.destroy(DisposableBeanAdapter.java:140) [7/28/09 0:14:32:227 MDT] 0000005a SystemErr R at org.springframework.beans.factory.support.DisposableBeanAdapter.run(DisposableBeanAdapter.java:134) [7/28/09 0:14:32:227 MDT] 0000005a SystemErr R at org.springframework.web.context.request.ServletRequestAttributes$DestructionCallbackBindingListener.valueUnbound(ServletRequestAttributes.java:269) [7/28/09 0:14:32:227 MDT] 0000005a SystemErr R at com.ibm.ws.webcontainer.httpsession.SessionData.processListeners(SessionData.java:924) [7/28/09 0:14:32:227 MDT] 0000005a SystemErr R at com.ibm.ws.webcontainer.httpsession.SessionData.checkSwappableListeners(SessionData.java:564) [7/28/09 0:14:32:227 MDT] 0000005a SystemErr R at com.ibm.ws.webcontainer.httpsession.DatabaseSessionData.checkSwappableListeners(DatabaseSessionData.java:331) [7/28/09 0:14:32:227 MDT] 0000005a SystemErr R at com.ibm.ws.webcontainer.httpsession.SessionData.sessionUnbound(SessionData.java:997) [7/28/09 0:14:32:227 MDT] 0000005a SystemErr R at com.ibm.ws.webcontainer.httpsession.SessionContext.notifySessionInvalidated(SessionContext.java:1100) [7/28/09 0:14:32:227 MDT] 0000005a SystemErr R at com.ibm.ws.webcontainer.httpsession.SessionData.invalidate(SessionData.java:621) [7/28/09 0:14:32:227 MDT] 0000005a SystemErr R at com.ibm.ws.webcontainer.httpsession.SessionData.internalInvalidate(SessionData.java:586) [7/28/09 0:14:32:227 MDT] 0000005a SystemErr R at com.ibm.ws.webcontainer.httpsession.DRSSessionData.internalInvalidate(DRSSessionData.java:252) [7/28/09 0:14:32:227 MDT] 0000005a SystemErr R at com.ibm.ws.webcontainer.httpsession.HttpSessDRSCacheMsgListener.response(HttpSessDRSCacheMsgListener.java:524) [7/28/09 0:14:32:227 MDT] 0000005a SystemErr R at com.ibm.ws.drs.stack.DRSClientCallback.processRcvMessage(DRSClientCallback.java:393) [7/28/09 0:14:32:227 MDT] 0000005a SystemErr R at com.ibm.ws.drs.stack.DRSStack.processRcvMessage(DRSStack.java:295) [7/28/09 0:14:32:227 MDT] 0000005a SystemErr R at com.ibm.ws.drs.DRSDomain.messageReceived(DRSDomain.java:536) [7/28/09 0:14:32:227 MDT] 0000005a SystemErr R at com.ibm.ws.drs.ha.DRSAgentClassEvents$1.run(DRSAgentClassEvents.java:714) [7/28/09 0:14:32:227 MDT] 0000005a SystemErr R at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1469)

    QOS.ch JIRA | 7 years ago | Mike Youngstrom
    java.lang.NullPointerException
  2. 0

    WARNING: Exception processing manager org.apache.catalina.session.StandardManager@1bc887b background process java.lang.NullPointerException at org.apache.commons.logging.impl.SLF4JLocationAwareLog.isDebugEnabled(SLF4JLocationAwareLog.java:59) at org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor.buildLifecycleMetadata(InitDestroyAnnotationBeanPostProcessor.java:201) at org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor.findLifecycleMetadata(InitDestroyAnnotationBeanPostProcessor.java:182) at org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor.postProcessBeforeDestruction(InitDestroyAnnotationBeanPostProcessor.java:160) at org.springframework.beans.factory.support.DisposableBeanAdapter.destroy(DisposableBeanAdapter.java:140) at org.springframework.beans.factory.support.DisposableBeanAdapter.run(DisposableBeanAdapter.java:134) at org.springframework.web.context.request.ServletRequestAttributes$DestructionCallbackBindingListener.valueUnbound(ServletRequestAttributes.java:269) at org.apache.catalina.session.StandardSession.removeAttributeInternal(StandardSession.java:1649) at org.apache.catalina.session.StandardSession.expire(StandardSession.java:756) at org.apache.catalina.session.StandardSession.isValid(StandardSession.java:592) at org.apache.catalina.session.ManagerBase.processExpires(ManagerBase.java:682) at org.apache.catalina.session.ManagerBase.backgroundProcess(ManagerBase.java:667) at org.apache.catalina.core.ContainerBase.backgroundProcess(ContainerBase.java:1316) at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1601) at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1610) at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1610) at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(ContainerBase.java:1590) at java.lang.Thread.run(Unknown Source)

    Spring JIRA | 8 years ago | Rusty Wright
    java.lang.NullPointerException
  3. 0

    WARNING: Exception processing manager org.apache.catalina.session.StandardManager@1bc887b background process java.lang.NullPointerException at org.apache.commons.logging.impl.SLF4JLocationAwareLog.isDebugEnabled(SLF4JLocationAwareLog.java:59) at org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor.buildLifecycleMetadata(InitDestroyAnnotationBeanPostProcessor.java:201) at org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor.findLifecycleMetadata(InitDestroyAnnotationBeanPostProcessor.java:182) at org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor.postProcessBeforeDestruction(InitDestroyAnnotationBeanPostProcessor.java:160) at org.springframework.beans.factory.support.DisposableBeanAdapter.destroy(DisposableBeanAdapter.java:140) at org.springframework.beans.factory.support.DisposableBeanAdapter.run(DisposableBeanAdapter.java:134) at org.springframework.web.context.request.ServletRequestAttributes$DestructionCallbackBindingListener.valueUnbound(ServletRequestAttributes.java:269) at org.apache.catalina.session.StandardSession.removeAttributeInternal(StandardSession.java:1649) at org.apache.catalina.session.StandardSession.expire(StandardSession.java:756) at org.apache.catalina.session.StandardSession.isValid(StandardSession.java:592) at org.apache.catalina.session.ManagerBase.processExpires(ManagerBase.java:682) at org.apache.catalina.session.ManagerBase.backgroundProcess(ManagerBase.java:667) at org.apache.catalina.core.ContainerBase.backgroundProcess(ContainerBase.java:1316) at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1601) at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1610) at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1610) at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(ContainerBase.java:1590) at java.lang.Thread.run(Unknown Source)

    Spring JIRA | 8 years ago | Rusty Wright
    java.lang.NullPointerException
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    Thinking In Software: January 2011

    blogspot.com | 11 months ago
    java.lang.NullPointerException

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. java.lang.NullPointerException

      No message provided

      at org.apache.commons.logging.impl.SLF4JLocationAwareLog.isDebugEnabled()
    2. Apache Commons Logging
      SLF4JLocationAwareLog.isDebugEnabled
      1. org.apache.commons.logging.impl.SLF4JLocationAwareLog.isDebugEnabled(SLF4JLocationAwareLog.java:59)
      1 frame
    3. Spring Beans
      DisposableBeanAdapter.run
      1. org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor.buildLifecycleMetadata(InitDestroyAnnotationBeanPostProcessor.java:201)
      2. org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor.findLifecycleMetadata(InitDestroyAnnotationBeanPostProcessor.java:182)
      3. org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor.postProcessBeforeDestruction(InitDestroyAnnotationBeanPostProcessor.java:160)
      4. org.springframework.beans.factory.support.DisposableBeanAdapter.destroy(DisposableBeanAdapter.java:140)
      5. org.springframework.beans.factory.support.DisposableBeanAdapter.run(DisposableBeanAdapter.java:134)
      5 frames
    4. Spring
      ServletRequestAttributes$DestructionCallbackBindingListener.valueUnbound
      1. org.springframework.web.context.request.ServletRequestAttributes$DestructionCallbackBindingListener.valueUnbound(ServletRequestAttributes.java:269)
      1 frame
    5. com.ibm.ws
      ThreadPool$Worker.run
      1. com.ibm.ws.webcontainer.httpsession.SessionData.processListeners(SessionData.java:924)
      2. com.ibm.ws.webcontainer.httpsession.SessionData.checkSwappableListeners(SessionData.java:564)
      3. com.ibm.ws.webcontainer.httpsession.DatabaseSessionData.checkSwappableListeners(DatabaseSessionData.java:331)
      4. com.ibm.ws.webcontainer.httpsession.SessionData.sessionUnbound(SessionData.java:997)
      5. com.ibm.ws.webcontainer.httpsession.SessionContext.notifySessionInvalidated(SessionContext.java:1100)
      6. com.ibm.ws.webcontainer.httpsession.SessionData.invalidate(SessionData.java:621)
      7. com.ibm.ws.webcontainer.httpsession.SessionData.internalInvalidate(SessionData.java:586)
      8. com.ibm.ws.webcontainer.httpsession.DRSSessionData.internalInvalidate(DRSSessionData.java:252)
      9. com.ibm.ws.webcontainer.httpsession.HttpSessDRSCacheMsgListener.response(HttpSessDRSCacheMsgListener.java:524)
      10. com.ibm.ws.drs.stack.DRSClientCallback.processRcvMessage(DRSClientCallback.java:393)
      11. com.ibm.ws.drs.stack.DRSStack.processRcvMessage(DRSStack.java:295)
      12. com.ibm.ws.drs.DRSDomain.messageReceived(DRSDomain.java:536)
      13. com.ibm.ws.drs.ha.DRSAgentClassEvents$1.run(DRSAgentClassEvents.java:714)
      14. com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1469)
      14 frames