CDI: beans.xml, where do I put you?

For EJB and JAR packaging you should place the beans.xml in src/main/resources/META-INF/. For WAR packaging you should place the beans.xml in src/main/webapp/WEB-INF/. Remember that only .java files should be put in the src/main/java and src/test/java directories. Resources like .xml files should be in src/main/resources.

How to create a modular JSF 2.0 application?

I understand that your question basically boils down to How can I include Facelets views in a JAR? You can do this by placing a custom ResourceResolver in the JAR. public class FaceletsResourceResolver extends ResourceResolver { private ResourceResolver parent; private String basePath; public FaceletsResourceResolver(ResourceResolver parent) { this.parent = parent; this.basePath = “/META-INF/resources”; // TODO: Make … Read more