users@glassfish.java.net

Re: Can not deploy inherited\shared bean

From: <glassfish_at_javadesktop.org>
Date: Thu, 02 Sep 2010 20:19:52 PDT

The test-dao jar contains the EJB bean class which implements the local interface. This jar is included in the WEB-INF/lib directory of the war. This means the same Bean class is packaged twice, once in the ejb jar, and once in the war file by the inclusion of the ejb jar file in the WEB-INF/lib directory.
In EE6/v3, if you package a Bean class inside war file, it makes that war a "EJB in war" case (EJB lite) and the Bean class will be processed. While as in EE5/v2, this Bean class does not make any sense in the war and is just ignored.
You should only package the EJB interfaces inside the war. Does the base-dao.jar contain the interface already, if yes, you could just remove test-dao.jar from WEB-INF/lib and it should just work.
Additionally the base-dao.jar is already in the ear lib directory which is visible to the web module, so you don't need to include it again in the WEB-INF/lib.
[Message sent by forum member 'hzhang_jn']

http://forums.java.net/jive/thread.jspa?messageID=481766