Hi all,
I currently have a J2EE project containing an EJB and a WAR. Everything goes fine while I have only one WAR and one EJB module bundled in the final EAR. I now need to develop an other WAR using the same EJB module.
So, I added the EJB module in the library of the new WAR. The problem is when I try to deploy the EAR bundled with the two WAR and the shared EJB, I get the following exception :
Caused by: java.lang.RuntimeException: Error while binding JNDI name com.alex.ejb.MyBeanRemote__3_x_Internal_RemoteBusinessHome__ for EJB : MyBean
As I remove the EJB from the library of the second WAR, everything work again.
Is there something I missed ?
Finally, the real question is "how to share an EJB within multiple web applications ?"
Thanks for help