how do I use multiple compilation outputs?

For my exploded J2EE applications the web .class files are located under webapp/WEB-INF/classes while the EJB .class files are located under ejb/
How do I set up IDEA to use two different output paths for the web classes and the ejb classes? If this is currently not supported, it would be great if IDEA supported this. The
reason is that during development it is normal to work with exploded J2EE applications instead of keep generation the .ear file every time a change is done. E.g. in weblogic an
exploded J2EE app will look like this:

myapp/met-inf/application.xml

myapp/ejb/com/mypackage/LocalMyEjbHome.class
myapp/ejb/com/mypackage/LocalMyEjb.class
myapp/ejb/com/mypackage/MyEjbBean.class
myapp/ejb/meta-inf/ejb-jar.xml
myapp/ejb/meta-inf/weblogic-cmp-rdbms-jar.xml
myapp/ejb/meta-inf/weblogic-jar.xml

myapp/webapp/mypage.jsp
myapp/webapp/web-inf/classes/com/mypackage/MyAction.class
myapp/webapp/lib/struts.jar
myapp/webapp/web.xml
myapp/webapp/struts-config.xml
myapp/webapp/taglibs/struts-bean.tld
etc..

So, in this case the com.mypackage.MyAction.java class needs to compile to myapp/webapp/web-inf/classes/ while the com.mypackage.MyEjbBean.java class needs to compile to
myapp/ejb/com/mypackage/

Any hints on how to do this would be greatly appreciated. Thanks!

/Pal Hoye


Please sign in to leave a comment.