Read the specs. Google for "j2ee specification", "servlet specification", and "ejb specification" and go grab them from sun. They're all in PDF, and pretty dense. JBoss 3.2 also has complete and very well commented dtd's for every xml descriptor or config file in docs/dtd, and html-ified versions of these in the html-svg subdirectory (you'll need an svg viewer, like adobe's).
They all go in WEB-INF, except for a few which can go into META-INF. What you really need is a book, like the JBoss pay docs (only $10). Anything by O'Reilly is also good, just make sure it covers the latest versions.
Thank U VM