I hope I'm missing something, but others have asked about this on the forums without getting any response.
I have a J2EE project (Struts with EJBs) arranged like this:
All Java code for the EJBs and Struts and shared code is in the src/ dir. This is a pretty typical way to organize a J2EE project.
(As an aside IntelliJ uses bin/ and web_exploded/. Ant uses build/ and web/ for its staging areas. I seperate the IDE's build directories from Ant's build directories so I can tell if build.xml is missing anything or if my IDE project is missing anything. Using seperate directories for the IDE and Ant builds will prevent one from concealing a mistake in the other.)
I need two modules, ejb and web. I need to create the web module in the project/ dir so it can get to the Struts source code in src/. So far so good.
I need to create the ejb module in the project/ dir so it can find the ejb-jar.xml in deploy.descr/ and put its output in bin/. When I try to create the ejb module in the project/ dir the wizzard refuses because the web module uses project/ as its root.
Another is that the wizzard won't let you use a directory parallel to the module root. If I could do this I could put deploy.descr/ in src/ and use src/ as the ejb module root, but then I'dt get the output under src/ instead of parallel to src/ in bin/.
Apparently IntelliJ forces me to create another level with two directories below project/ so it can have two different module roots and then make the ejb module a dependency of the web module. Then I'd have to re-write the Ant script to accomodate this kludge.
I haven't been able to find any documentation on how IntelliJ treats projects and modules except for some pictures of their wizzards. I've asked support and they've sent me more pictures of their wizzards. Is there any documentation on this? Am I just forced to do what I mentioned in the previous paragraph?
If IntelliJ is really this stupid about setting up modules in a project then it is a serious architectural screw up.