users@glassfish.java.net

CDI: with interfaces in one jar, impls in another, how many beans.xml files?

From: <forums_at_java.net>
Date: Tue, 09 Nov 2010 09:33:35 -0800

Circling back to try to get CDI working now that the Weld guys claim it works
fine in Glassfish 3.1.  That would be great.

Want to make sure I'm doing everything by the book.

I have a set of interfaces in a jar file in an ear's lib directory.

In that ear I have an ejb jar that has EJB classes in it that implement those
interfaces.

Should I:

  * put a META-INF/beans.xml file in the EJB jar? (clearly yes)
  * put a META-INF/beans.xml file in the jar containing interfaces?

The second point is where I am unclear on what the specification says.

http://seamframework.org/Community/ManyJarsBeansxmlInAllOfThem is the
equivalent posting over on the Weld forums; it will be interesting to see if
there is agreement.  :-)

Best,

Laird


--
[Message sent by forum member 'ljnelson']
View Post: http://forums.java.net/node/714558