[jboss-user] [EJB 3.0] - Accessing EJB3 Session Beans from a JAR in a WAR?

bsheward do-not-reply at jboss.com
Thu Aug 10 21:57:47 EDT 2006


Hi,

I've created a JAR file, within a WAR file, deployed within an EAR file into JBoss 4.0.4. The JAR file contains JUnit tests which I've hooked into J2EEUnit.

The problem is that the tests in the JAR file don't seem to be able to find the Session Beans.

I've tried all sorts of names in an InitialContext.lookup(), the compiler crashed when I tried using @EJB in the JUnit test classes, but I wonder if I need to do something in the WARs web.xml to expose the EJBs in a similar way to with EJB 2.

Can anyone please point me in the right direction? The O'Reilly book only seems to deal with a separate application, not a web application.

Thanks and Regards,

Barry


View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3964520#3964520

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3964520



More information about the jboss-user mailing list