General J2EE: How to invoke EJB's from a client on the same JVM
I have 5 EJBs deployed using a single .EAR file containing the deployable jars for each EJB as componenets. I have an utitlity class that needs to invoke methods on one of these EJB's i.e. basically getting the home and remote interfaces of the EJB. The home and remote interfaces are in the EJB jar file which is one of the components in the .EAR file. The utility class is not able to see the home or remote interface classes of the EJB. The problem here is that both the EJB and the utility class (which is the client) are in the same JVM. I cannot specify the home and remote interfaces in the weblogic classpath as the WLS says the EJB cannot be deployed at run time as it finds the home and remote interface classes in its own jar file as well as in the weblogic class path. I am frantically looking for a solution on this issue.
- Posted by: Raghuraman T.R
- Posted on: August 17 2001 16:25 EDT
Can someone please help me out ?
See the doc on 6.x classloading: http://e-docs.bea.com/wls/docs61/programming/packaging.html#1051556
If you client needs to acess EJB's and it is not deployed in the same deployment unit (EAR), you must deploy EJB home and remote interfaces with your client (even in the same JVM).