Why don't you put all your stuff under Tomcat? With Struts 1.1, it's
possible to define several contexts for your application (i.e. have several
struts-config.xml files) and this seems to me the solution which possibly
could address your needs. Additionally, if you have the possibility, the
ideal solution would be a mixture between Apache httpd and Tomcat, so that
HTML is served by Apache which guarantees better performances.
I know that the security issue is a 'pain in the ass' (I'm writing my
security model but the reason is that I'm guaranteeing security on the EJB
tier, and there is no vendor-independent security solution at present), but
if you need only to check security at the web-lier, I would seriously think
to implement the security using Tomcat native architecture, with one of its
security realms modules.
Hope this will help,
Marco
- Original Message -
From: Bob Langford [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Sunday, September 07, 2003 1:19 AM
Subject: Advice wanted about mapping URIs to pages
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]
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]