0 Replies Latest reply on Dec 29, 2005 6:03 AM by Abhilash Kumar

    NPE from interceptor from MDB calling SSB method

    Abhilash Kumar Newbie

      Hello:

      I have a topic listener MDB calling a state less session bean method. Both have Tx type as CMT. I get the following NPE stack trace whenever the onMessage() is called. The exception is thrown after the SSB method completes successfully. The problem vanishes if i remove the SSB method call from onMessage()

      I am using Jboss 3.2.7. Can anyone throw some light into this issue ? Any pointers will be very helpful.

      thanks and regards,

      -- Kannan.


      16:25:36,671 ERROR [LogInterceptor] RuntimeException in method: public abstract void javax.jms.MessageListener.onMessage(javax.jms.Message)
      java.lang.NullPointerException
      at $Proxy173.createMaster(Unknown Source)
      at org.foo.MastersSubscriberMDB.onMessage(MastersSubscriberMDB.java:76)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:324)
      at org.jboss.ejb.MessageDrivenContainer$ContainerInterceptor.invoke(MessageDrivenContainer.java:458)
      at org.jboss.resource.connectionmanager.CachedConnectionInterceptor.invoke(CachedConnectionInterceptor.java:186)
      at org.jboss.ejb.plugins.MessageDrivenInstanceInterceptor.invoke(MessageDrivenInstanceInterceptor.java:62)
      at org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:84)
      at org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:284)
      at org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:150)
      at org.jboss.ejb.plugins.RunAsSecurityInterceptor.invoke(RunAsSecurityInterceptor.java:90)
      at org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:192)
      at org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invoke(ProxyFactoryFinderInterceptor.java:122)
      at org.jboss.ejb.MessageDrivenContainer.internalInvoke(MessageDrivenContainer.java:372)
      at org.jboss.ejb.Container.invoke(Container.java:709)
      at org.jboss.ejb.plugins.jms.JMSContainerInvoker.invoke(JMSContainerInvoker.java:928)
      at org.jboss.ejb.plugins.jms.JMSContainerInvoker$MessageListenerImpl.onMessage(JMSContainerInvoker.java:1205)
      at org.jboss.jms.asf.StdServerSession.onMessage(StdServerSession.java:276)
      at org.jboss.mq.SpyMessageConsumer.sessionConsumerProcessMessage(SpyMessageConsumer.java:904)
      at org.jboss.mq.SpyMessageConsumer.addMessage(SpyMessageConsumer.java:159)
      at org.jboss.mq.SpySession.run(SpySession.java:351)
      at org.jboss.jms.asf.StdServerSession.run0(StdServerSession.java:200)
      at org.jboss.jms.asf.StdServerSession.run(StdServerSession.java:180)
      at EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(PooledExecutor.java:743)
      at java.lang.Thread.run(Thread.java:534)
      16:25:36,687 ERROR [JMSContainerInvoker] Exception in JMSCI message listener
      javax.ejb.EJBException: RuntimeException; CausedByException is:
      null
      at org.jboss.ejb.plugins.LogInterceptor.handleException(LogInterceptor.java:382)
      at org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:196)
      at org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invoke(ProxyFactoryFinderInterceptor.java:122)
      at org.jboss.ejb.MessageDrivenContainer.internalInvoke(MessageDrivenContainer.java:372)
      at org.jboss.ejb.Container.invoke(Container.java:709)
      at org.jboss.ejb.plugins.jms.JMSContainerInvoker.invoke(JMSContainerInvoker.java:928)
      at org.jboss.ejb.plugins.jms.JMSContainerInvoker$MessageListenerImpl.onMessage(JMSContainerInvoker.java:1205)
      at org.jboss.jms.asf.StdServerSession.onMessage(StdServerSession.java:276)
      at org.jboss.mq.SpyMessageConsumer.sessionConsumerProcessMessage(SpyMessageConsumer.java:904)
      at org.jboss.mq.SpyMessageConsumer.addMessage(SpyMessageConsumer.java:159)
      at org.jboss.mq.SpySession.run(SpySession.java:351)
      at org.jboss.jms.asf.StdServerSession.run0(StdServerSession.java:200)
      at org.jboss.jms.asf.StdServerSession.run(StdServerSession.java:180)
      at EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(PooledExecutor.java:743)
      at java.lang.Thread.run(Thread.java:534)
      java.lang.NullPointerException
      at $Proxy173.createMaster(Unknown Source)
      at org.foo.MastersSubscriberMDB.onMessage(MastersSubscriberMDB.java:76)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:324)
      at org.jboss.ejb.MessageDrivenContainer$ContainerInterceptor.invoke(MessageDrivenContainer.java:458)
      at org.jboss.resource.connectionmanager.CachedConnectionInterceptor.invoke(CachedConnectionInterceptor.java:186)
      at org.jboss.ejb.plugins.MessageDrivenInstanceInterceptor.invoke(MessageDrivenInstanceInterceptor.java:62)
      at org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:84)
      at org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:284)
      at org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:150)
      at org.jboss.ejb.plugins.RunAsSecurityInterceptor.invoke(RunAsSecurityInterceptor.java:90)
      at org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:192)
      at org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invoke(ProxyFactoryFinderInterceptor.java:122)
      at org.jboss.ejb.MessageDrivenContainer.internalInvoke(MessageDrivenContainer.java:372)
      at org.jboss.ejb.Container.invoke(Container.java:709)
      at org.jboss.ejb.plugins.jms.JMSContainerInvoker.invoke(JMSContainerInvoker.java:928)
      at org.jboss.ejb.plugins.jms.JMSContainerInvoker$MessageListenerImpl.onMessage(JMSContainerInvoker.java:1205)
      at org.jboss.jms.asf.StdServerSession.onMessage(StdServerSession.java:276)
      at org.jboss.mq.SpyMessageConsumer.sessionConsumerProcessMessage(SpyMessageConsumer.java:904)
      at org.jboss.mq.SpyMessageConsumer.addMessage(SpyMessageConsumer.java:159)
      at org.jboss.mq.SpySession.run(SpySession.java:351)
      at org.jboss.jms.asf.StdServerSession.run0(StdServerSession.java:200)
      at org.jboss.jms.asf.StdServerSession.run(StdServerSession.java:180)
      at EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(PooledExecutor.java:743)
      at java.lang.Thread.run(Thread.java:534)