I'm trying to decide how to lay out my application. The major question is how to make Tomcat run it, but ideas for better organization would be welcome also.
I'd better describe the setup, even though it's a bit lengthy. I'm running a separate instance of Tomcat, dedicated to this project. It's got two major sections: access control and content. 1) The access control is a set of JSP pages (using Struts) that handle user signup, login, etc. I have written a <Filter> that checks credentials on each page. 2) The content is a bunch of static HTML, GIFs, Flash, etc. Down the road there will also be some JSP here. This stuff is written by another person, and mostly already exists.
I'd like to have the directory | Accessed from URI's such as these: layout like this: |
./tomcat/webapps/control.war xyz.com/ ./web/public/*.html xyz.com/public/foo.html ./web/basic/*.html xyz.com/good/bar.html ./web/deluxe/*.html xyz.com/better/some.pdf ./web/premier/*.html xyz.com/best/cool.swf
The first one seems straightforward. The others are a bit harder. It's not going to be possible to put them into a .WAR file, and they're going to be updated constantly. They're not under the $CATALINA_BASE/webapps directory, so I don't know how to tell Tomcat to find them. Maybe symbolic links?
The hard part is context. My custom <Filter> has to apply to all the directories
under ./web, but also access the Session and other data that is part of control.war,
and I've had trouble doing that. It would be easy to have them be separate apps,
but I can't get my authentication working that way.
Any suggestions or ideas would be greatly appreciated. I'm still experimenting,
but I feel like every idea I've tried is an ugly hack. I'd rather be elegant :-)
Thanks!
P.S. Infrastructure: Linux 2.4.x, Tomcat 4.1.27, Struts 1.1. Solutions don't
have to be portable to other software. I'd rather not use Tomcat 5, though. (Yet)
--
Bob Langford
Silicon Masters Consulting, Inc. 8207 Stone River Court, Richmond, VA 23235
phone: 804-674-1253 fax: 804-745-6650 http://www.silicon-masters.com/
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]