RE: Is there such a beast ? (virtual directories)

2004-07-14 Thread David . Pawson
> Mike Curwen wrote:
>>
>> 
>>   
>>
>>
> I think this syntax would confuse Tomcat. I thought only 
one  
> tag is allowed ...? I could be wrong.

No, you can have as many contexts as you like...


What happens when the context element is root of a document
in conf/catalina/localhost (version 5) ?
3 files all relating to the same app?

regards DaveP

** snip here **

-- 
DISCLAIMER: 

NOTICE: The information contained in this email and any attachments is 
confidential and may be privileged. If you are not the intended 
recipient you should not use, disclose, distribute or copy any of the 
content of it or of any attachment; you are requested to notify the 
sender immediately of your receipt of the email and then to delete it 
and any attachments from your system. 

RNIB endeavours to ensure that emails and any attachments generated by 
its staff are free from viruses or other contaminants. However, it 
cannot accept any responsibility for any  such which are transmitted.
We therefore recommend you scan all attachments. 

Please note that the statements and views expressed in this email and 
any attachments are those of the author and do not necessarily represent 
those of RNIB. 

RNIB Registered Charity Number: 226227 

Website: http://www.rnib.org.uk 

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Is there such a beast ? (virtual directories)

2004-07-13 Thread Justin Ruthenbeck
At 12:13 PM 7/13/2004, you wrote:
One option is to use a servlet that serves static files from directories 
and map that servlet in your web application's web.xml.  This is nowhere 
near as robust or secure as putting httpd infront of your servlet 
containers.  Again since this _could_ point outside the application 
directory it's a poor solution.
This approach is what we've done to use shared resources (static content) 
amongst multiple apps.  In some deployment environments, running Apache 
in front of Tomcat is a no-go for our customers, so implementing this way 
allows us to *optionally* use Apache:

If Apache present, image is at http://www.site.com/images/a.gif
and physically at /.../images/a.gif
If Apache is not present, image is at 
http://www.site.com/webAppA/static?a.gif
and physically at /.../images/a.gif

Point being, implementing the serving as a separate servlet can give you 
additional flexibility at deployment time.  The assertion that this 
diminishes robustness and/or security must be taken in context -- in many 
situations, this can be preferable to running with Apache in front.  As 
always, YMMV.

justin

Otherwise (as in Carl's suggestion): You can "overlap" URI mappings to 
contexts.

So you can map:
/app1  ->   fooApplication.war
/app1/images  -> /usr/home/tomcat/images
as long as your images directory is a deployable web application.
Original Message Follows
From: "Mike Curwen" <[EMAIL PROTECTED]>
Reply-To: "Tomcat Users List" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Subject: Is there such a beast ?  (virtual directories)
Date: Tue, 13 Jul 2004 10:12:56 -0500
Hello all,
I had a friend ask me on the phone a couple days ago, and now a question
has popped up at javaranch. I've looked in the docs and googled, but
haven't found a definitive 'no' answer (shouldn't life be that simple?).
Thought I'd ask here.
Is there such a thing as directory aliasing / virtual directories (like
you get in Apache), available in Tomcat?
so you'd specify that /images is *really* over here at
/usr/local/some/funky/place/images
I like to tell people they don't need Apache, unless they're doing
"special" stuff.  Would this be one of those "special" things ?

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


RE: Is there such a beast ? (virtual directories)

2004-07-13 Thread Erik Earle
This goes against the grain of the servlet spec. Generally, images would be 
something tied to a web application and would therefore be contained within 
the application war file (or directory) so that the webapp would be deployed 
as a single unit.

...but I'm not a puriest so have at it :P
One option is to use a servlet that serves static files from directories and 
map that servlet in your web application's web.xml.  This is nowhere near as 
robust or secure as putting httpd infront of your servlet containers.  Again 
since this _could_ point outside the application directory it's a poor 
solution.

Otherwise (as in Carl's suggestion): You can "overlap" URI mappings to 
contexts.

So you can map:
/app1  ->   fooApplication.war
/app1/images  -> /usr/home/tomcat/images
as long as your images directory is a deployable web application.
Original Message Follows
From: "Mike Curwen" <[EMAIL PROTECTED]>
Reply-To: "Tomcat Users List" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Subject: Is there such a beast ?  (virtual directories)
Date: Tue, 13 Jul 2004 10:12:56 -0500
MIME-Version: 1.0
Received: from mail.apache.org ([209.237.227.199]) by mc4-f28.hotmail.com 
with Microsoft SMTPSVC(5.0.2195.6824); Tue, 13 Jul 2004 08:13:17 -0700
Received: (qmail 41774 invoked by uid 500); 13 Jul 2004 15:13:05 -
Received: (qmail 41755 invoked by uid 99); 13 Jul 2004 15:13:05 -
Received: from [139.142.220.22] (HELO brad.globallyboundless.com) 
(139.142.220.22)  by apache.org (qpsmtpd/0.27.1) with ESMTP; Tue, 13 Jul 
2004 08:13:02 -0700
Received: from BALTHAZAR ([10.0.0.111])by mail.gb-im.com (8.10.2/8.10.2) 
with ESMTP id i6DFCuV12696for <[EMAIL PROTECTED]>; Tue, 13 Jul 
2004 10:12:56 -0500
X-Message-Info: JGTYoYF78jFNeFApfa+UFHTL+Uj4Gjtk
Mailing-List: contact [EMAIL PROTECTED]; run by ezmlm
Precedence: bulk
List-Unsubscribe: <mailto:[EMAIL PROTECTED]>
List-Subscribe: <mailto:[EMAIL PROTECTED]>
List-Help: <mailto:[EMAIL PROTECTED]>
List-Post: <mailto:[EMAIL PROTECTED]>
List-Id: "Tomcat Users List" 
Delivered-To: mailing list [EMAIL PROTECTED]
X-ASF-Spam-Status: No, hits=0.0 required=10.0tests=FROM_HAS_ULINE_NUMS
X-Spam-Check-By: apache.org
Message-ID: <[EMAIL PROTECTED]>
X-MSMail-Priority: Normal
X-Mailer: Microsoft Outlook, Build 10.0.3416
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1409
X-Virus-Checked: Checked
Return-Path: 
[EMAIL PROTECTED]
X-OriginalArrivalTime: 13 Jul 2004 15:13:17.0305 (UTC) 
FILETIME=[ECD2AE90:01C468EB]

Hello all,
I had a friend ask me on the phone a couple days ago, and now a question
has popped up at javaranch. I've looked in the docs and googled, but
haven't found a definitive 'no' answer (shouldn't life be that simple?).
Thought I'd ask here.
Is there such a thing as directory aliasing / virtual directories (like
you get in Apache), available in Tomcat?
so you'd specify that /images is *really* over here at
/usr/local/some/funky/place/images
I like to tell people they don't need Apache, unless they're doing
"special" stuff.  Would this be one of those "special" things ?

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
_
MSN Toolbar provides one-click access to Hotmail from any Web page – FREE 
download! http://toolbar.msn.click-url.com/go/onm00200413ave/direct/01/

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: Is there such a beast ? (virtual directories)

2004-07-13 Thread QM
On Wed, Jul 14, 2004 at 12:07:30AM +0800, Chong Yu Meng wrote:
: >
: >  
: >  
: >

: I think this syntax would confuse Tomcat. I thought only one  
: tag is allowed ...? I could be wrong.

Not true -- one Tomcat virtual host may serve several webapps (contexts).

-QM

-- 

software  -- http://www.brandxdev.net
tech news -- http://www.RoarNetworX.com


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Is there such a beast ? (virtual directories)

2004-07-13 Thread David Rees
Chong Yu Meng wrote, On 7/13/2004 9:07 AM:
Mike Curwen wrote:

  
  

I think this syntax would confuse Tomcat. I thought only one  
tag is allowed ...? I could be wrong.
No, you can have as many contexts as you like...
-Dave
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: Is there such a beast ? (virtual directories)

2004-07-13 Thread Chong Yu Meng
Hi Mike,
Mike Curwen wrote:
Hm... would that work in this case:

  
  

 

I think this syntax would confuse Tomcat. I thought only one  
tag is allowed ...? I could be wrong.

Regards,
pascal chong
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


RE: Is there such a beast ? (virtual directories)

2004-07-13 Thread Mike Curwen
Hm... would that work in this case:


   
   



then from the browser I'd want:

http://www.mydomain.com/foo-app/images
 
to look inside /some/other/path


(the virtual directory should only be available from within foo-app).


> -Original Message-
> From: Carl Olivier [mailto:[EMAIL PROTECTED] 
> Sent: Tuesday, July 13, 2004 10:14 AM
> To: Tomcat Users List
> Subject: RE: Is there such a beast ? (virtual directories)
> 
> 
> Inside a host you could add a  docBase="/usr/local/somewhere" /> 
> 
> Regards,
> 
> Carl
> 
> -Original Message-
> From: Mike Curwen [mailto:[EMAIL PROTECTED] 
> Sent: 13 July 2004 05:13 PM
> To: [EMAIL PROTECTED]
> Subject: Is there such a beast ? (virtual directories)
> 
> Hello all,
> 
> I had a friend ask me on the phone a couple days ago, and now 
> a question has popped up at javaranch. I've looked in the 
> docs and googled, but haven't found a definitive 'no' answer 
> (shouldn't life be that simple?). Thought I'd ask here.
>   
> Is there such a thing as directory aliasing / virtual 
> directories (like you get in Apache), available in Tomcat?
>  
> so you'd specify that /images is *really* over here at 
> /usr/local/some/funky/place/images
> 
> I like to tell people they don't need Apache, unless they're 
> doing "special" stuff.  Would this be one of those "special" things ?
> 
> 
> 
> 
> -
> 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]
> 


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Is there such a beast ? (virtual directories)

2004-07-13 Thread Carl Olivier
Inside a host you could add a  

Regards,

Carl

-Original Message-
From: Mike Curwen [mailto:[EMAIL PROTECTED] 
Sent: 13 July 2004 05:13 PM
To: [EMAIL PROTECTED]
Subject: Is there such a beast ? (virtual directories)

Hello all,

I had a friend ask me on the phone a couple days ago, and now a question has
popped up at javaranch. I've looked in the docs and googled, but haven't
found a definitive 'no' answer (shouldn't life be that simple?).
Thought I'd ask here.
  
Is there such a thing as directory aliasing / virtual directories (like you
get in Apache), available in Tomcat?
 
so you'd specify that /images is *really* over here at
/usr/local/some/funky/place/images

I like to tell people they don't need Apache, unless they're doing "special"
stuff.  Would this be one of those "special" things ?




-
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]



Is there such a beast ? (virtual directories)

2004-07-13 Thread Mike Curwen
Hello all,

I had a friend ask me on the phone a couple days ago, and now a question
has popped up at javaranch. I've looked in the docs and googled, but
haven't found a definitive 'no' answer (shouldn't life be that simple?).
Thought I'd ask here.
  
Is there such a thing as directory aliasing / virtual directories (like
you get in Apache), available in Tomcat?
 
so you'd specify that /images is *really* over here at
/usr/local/some/funky/place/images

I like to tell people they don't need Apache, unless they're doing
"special" stuff.  Would this be one of those "special" things ?




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]