Uploaded image for project: 'jBPM'
  1. jBPM
  2. JBPM-2988

"javax.ejb.NoSuchObjectLocalException: failed to retrieve command service home" when restarting JBoss with pending timer jobs

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Won't Do
    • Icon: Minor Minor
    • jBPM 3.2.x
    • jBPM 3.2.8
    • Runtime Engine
    • None
    • Workaround Exists
    • Hide

      Add the following <depends> line into jbpm-enterprise.jar/META-INF/jboss.xml:

      <entity>
      <ejb-name>TimerEntityBean</ejb-name>
      <jndi-name>jbpm/TimerEntityBean</jndi-name>
      <local-jndi-name>java:jbpm/TimerEntityBean</local-jndi-name>
      <depends>jboss.j2ee:jndiName=ejb/CommandServiceBean,service=EJB</depends>
      </entity>

      Show
      Add the following <depends> line into jbpm-enterprise.jar/META-INF/jboss.xml: <entity> <ejb-name>TimerEntityBean</ejb-name> <jndi-name>jbpm/TimerEntityBean</jndi-name> <local-jndi-name>java:jbpm/TimerEntityBean</local-jndi-name> <depends>jboss.j2ee:jndiName=ejb/CommandServiceBean,service=EJB</depends> </entity>

      In case you use TimerEntityBean in jbpm-enterprise.jar, you may see this error when you restart JBoss with pending timer jobs:

      [] 2010-11-25 11:32:38,513 14529 INFO [org.jboss.ejb.EjbModule] (main Deploying TimerEntityBean
      [] 2010-11-25 11:32:38,574 14590 INFO [org.jboss.ejb.EjbModule] (main Deploying CommandServiceBean
      [] 2010-11-25 11:32:38,582 14598 INFO [org.jboss.ejb.EjbModule] (main Deploying CommandListenerBean
      [] 2010-11-25 11:32:38,593 14609 INFO [org.jboss.ejb.EjbModule] (main Deploying JobListenerBean
      [] 2010-11-25 11:32:39,174 15190 INFO [org.jboss.ejb.plugins.local.BaseLocalProxyFactory] (main Bound EJB LocalHome 'TimerEntityBean' to jndi 'java:jbpm/TimerEntityBean'
      [] 2010-11-25 11:32:39,180 15196 INFO [org.jboss.proxy.ejb.ProxyFactory] (main Bound EJB Home 'TimerEntityBean' to jndi 'jbpm/TimerEntityBean'
      [] 2010-11-25 11:32:39,271 15287 ERROR [org.jboss.ejb.plugins.LogInterceptor] (EJB-Timer-1[target=jboss.j2ee:jndiName=jbpm/TimerEntityBean,service=EJB,pk=186267] EJBException in method: public abstract void javax.ejb.TimedObject.ejbTimeout(javax.ejb.Timer):
      javax.ejb.NoSuchObjectLocalException: failed to retrieve command service home
      at org.jboss.ejb.plugins.EntityInstanceInterceptor.invoke(EntityInstanceInterceptor.java:221)
      at org.jboss.ejb.plugins.EntityLockInterceptor.invoke(EntityLockInterceptor.java:104)
      at org.jboss.ejb.plugins.EntityCreationInterceptor.invoke(EntityCreationInterceptor.java:76)
      at org.jboss.ejb.plugins.CallValidationInterceptor.invoke(CallValidationInterceptor.java:63)
      at org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:121)
      at org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:350)
      at org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:181)
      at org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:168)
      at org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:205)
      at org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invoke(ProxyFactoryFinderInterceptor.java:138)
      at org.jboss.ejb.EntityContainer.internalInvoke(EntityContainer.java:527)
      at org.jboss.ejb.Container.invoke(Container.java:960)
      at org.jboss.ejb.txtimer.TimedObjectInvokerImpl.callTimeout(TimedObjectInvokerImpl.java:99)
      at org.jboss.ejb.txtimer.TimerImpl$TimerTaskImpl.run(TimerImpl.java:561)
      at java.util.TimerThread.mainLoop(Timer.java:512)
      at java.util.TimerThread.run(Timer.java:462)
      ....
      [] 2010-11-25 11:32:39,280 15296 ERROR [org.jboss.ejb.txtimer.TimerImpl] (EJB-Timer-5[target=jboss.j2ee:jndiName=jbpm/TimerEntityBean,service=EJB,pk=186577] Error invoking ejbTimeout: javax.ejb.NoSuchObjectLocalException: failed to retrieve command service home

      [] 2010-11-25 11:32:39,287 15303 INFO [org.jboss.ejb.plugins.local.BaseLocalProxyFactory] (main Bound EJB LocalHome 'CommandServiceBean' to jndi 'java:ejb/CommandServiceBean'
      [] 2010-11-25 11:32:39,290 15306 INFO [org.jboss.proxy.ejb.ProxyFactory] (main Bound EJB Home 'CommandServiceBean' to jndi 'ejb/CommandServiceBean'
      [] 2010-11-25 11:32:39,384 15400 INFO [org.jboss.ejb.EJBDeployer] (main Deployed: file:/opt/jboss-eap-4.3.3.CP07/server/project-t21_t/deploy/ext/jbpm/jbpm-enterprise-3.2.8_SOA.jar

      This error indicates that TimerEntityBean's ejb timer kicked in before CommandServiceBean was completely deployed.

        1. JBPM-2988.patch
          0.5 kB
          Toshiya Kobayashi

              marco.rietveld Marco Rietveld (Inactive)
              rhn-support-tkobayas Toshiya Kobayashi
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated:
                Resolved: