2 Replies Latest reply on May 14, 2004 8:34 AM by jae

    Hot deployment fails with EJB dependency across 2 EAR files

    Peter Davies Newbie

      I have two EAR files (A and B). Each contains a standard Stateless Session Bean among other things. Bean a in EAR A makes a standard EJB call to bean b in EAR B.

      We have found that hot deploying either of these EARs without the other causes problems. The following exception is generated:

      Caused by: javax.ejb.EJBException: Invalid invocation, check your deployment packaging, method=public abstract org.jtc.jtrace_udc20interface.jtc_adapter.api.JTC_UDC20AdapterRemote org.jtc.jtrace_udc20interface.jtc_adapter.api.JTC_UDC20AdapterHome.create() throws java.rmi.RemoteException,javax.ejb.CreateException
      at org.jboss.ejb.StatelessSessionContainer$ContainerInterceptor.invokeHo
      at org.jboss.resource.connectionmanager.CachedConnectionInterceptor.invo

      In testing this, we have found that if we hot deploy EAR B, wait one deployment scan and then hot deploy EAR A, the same error occurs. However, if we hot deploy EAR A and then EAR B one scan later, everything works normally. In addition, hot deploying them both in the same scan cycle works properly.

      I'm not sure what causes this, but I have duplicated it with several combinations of beans. Every logical cause that I can think of does not seem to hold water in the case of a simple hot deploy of EAR A, which fails. I can certainly imagine failure when hot deploying EAR B without A. However, there is no circular dependency, so A should be able to be hot deployed without B. It is also strange that I can deploy A then B, but not B then A.

      I would realy like to hot deply A without B as B has a wider number of clients and changes much less frequently.

      Anyone have any ideas what is causing this and if there is a work-around other than always hot deploying both? Combining the beans into a single EAR is not an option as they are created by different teams.