This is properly explained in "Professional Java Server Programming J2EE 1.3 Edition" by Wrox Press.
What you want to do is put the classes that are used in both war and ejb into a separate jar file. Put the jar file in the ear and reference it in a Class-Path ref in the manifest file. Now I discovered a bug just recently in JBoss that caused these dependent jars to not be deployed. Yesterday, I submitted a bug fix for this. I think I made the correct fix, but it remains to be seen if my fix finds its way into the next release. Greg Simon Stewart wrote: > This is something that I've been wrestling with, and I thought I'd ask > the experts. Imagine that you have an app composed of some EJBs, a web > tier and some Data Transfer (aka Value) Objects. Consider that the web > tier will be run in a seperate JVM from the EJBs. Where should the > DTOs be packaged? In the WAR? In the EJB.JAR? Or in both places? > > I suspect that the correct answer is "in both places" since this is > the only way that you can guarentee that they will be available to the > whole app. Won't this cause problems when the classes are used in the > same JVM, though? I've never really seen this properly explained, so > I'm keen to hear what you all have to say.... > > Regards, > > Simon > > -- > (if anyone can tell me why I'm wrapping everything in parentheses, I'd > be interested to know. I'm sure I had a good reason to do it, I'm just > not sure what it was.) --- Nix > > ------------------------------------------------------- > This sf.net email is sponsored by:ThinkGeek > Welcome to geek heaven. > http://thinkgeek.com/sf > _______________________________________________ > JBoss-user mailing list > [EMAIL PROTECTED] > https://lists.sourceforge.net/lists/listinfo/jboss-user -- Greg Turner, JBoss Authorized Consultant Tiburon Enterprise Systems http://www.tiburon-e-systems.com Box 1171 Tiburon, CA 94920 415-332-3363 ------------------------------------------------------- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf _______________________________________________ JBoss-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-user
