This week's book giveaway is in the OO, Patterns, UML and Refactoring forum. We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line! See this thread for details.
I'm trying to get started learning some technologies for a project I'm working on (struts2 on WebLogic 10), but I'm having a hard time getting just a very basic HelloWorld app going. I have never worked with enterprise java before. As I understand it, the J2EE specification calls for a specific directory structure for a web application. My goal is to put together an application that runs a filter to catch all references to .do files, captures the time they were created (just so I can get an attribute to save), then forwards the request to a JSP that prints a hello message and the time.
If I understand correctly, an enterprise web application needs the following structure (simplified): JSPs in the root directory, and a WEB-INF directory with web.xml and the server-side classes. I guess any referenced jars should go in WEB-INF/lib too.
So, my design is as follows:
I put these files into the following directory structure:
When I deploy to WL10, it says that it can prepare correctly but when I try to start it I get java.lang.ClassNotFoundException: world.hello.BasicFilter. I've tried moving the class files directly into the WEB-INF directory and into the HelloWorld directory as well...same error.
If anyone could point me along I would be very grateful! I'm excited to get a skeleton web app going so that I can begin to experiment with frameworks like struts and later Spring.
Ah thank you very much. I didn't realize that that was the convention. My next step will be to package these into an archive-- I believe the way to do this is to put together an Ant build file and create a war? I understand I could also use Maven...