EJB calling another EJB
I know that one EJB can call another, all that is needed is the home and interface classes.
But how do I avoid having 2 copies of these java files?
If I include EJB1.jar in EJB2's project library (using Studio Entersprise) I get a name collision when I deploy EJB2 on a Sun 1 Application Server.
I can extract the home and interface java files from EJB1 and include them in EJB2 and everthing is fine. But this means I have 2 copies of the home and interface files from EJB1.
How can I avoid this?
BTW, I am trying to port a giant Weblogic WAR file (poorly architected) consisting of a dozen or so interdependent EJBs, servlets, and jsps to the Sun Blueprint .
Thanks,
Bryan
[724 byte] By [
bryanut] at [2007-11-26 11:38:31]

# 2
thanks, it helps a little, but I am moving away from Weblogic. I have a sun-ejb-jar.xml file.
I can't figure out how to create a <reference> tag in sun-ejb-jar using Studio Enterprise.
Also it is unclear to how EjbA can reference EjbBHome at compile time without including EjbB.jar or having a copy of EjbBHome.java...
Maybe I am just confused.
thanks,
Bryan
# 3
Ref:
http://www.netbeans.org/source/browse/*checkout*/j2ee/platform/javahelp/org/net beans/modules/j2ee/platform/docs/ejb/editing/about_call_ejb.html
http://www.netbeans.org/source/browse/*checkout*/j2ee/platform/javahelp/org/net beans/modules/j2ee/platform/docs/ejb/editing/call_ejb.html
(available in the ide's javahelp too: invoke 'help|contents...' menu and search for 'reference'...)
you are right that the jar needs to be made available to the ide for compilation; i think the way to do that is to put it in its own project and refer to that project from the calling project...