Thanks for the reply and the thoughts about my question. 


Med vänlig hälsning
Andreas Imner
Systemutvecklare 
KG Knutsson AB
Autokatalogen

Tel: +46 8 92 34 37
Mobil: +46 70 606 34 37
andreas.im...@kgk.se 



-----Ursprungligt meddelande-----
Från: Pid [mailto:p...@pidster.com] 
Skickat: den 20 maj 2009 11:14
Till: Tomcat Users List
Ämne: Re: Making Apache httpd fallback to local file after receiving 404 from 
backend Tomcat?

Imner, Andreas wrote:
> Hi all
> 
> I'm setting up a website using Apache webserver 2.2.11 / mod_jk 1.2.28 
> (Windows Server 2000) that connects to two 
> backend Apache Tomcat 6.0.18 server (Windows Server 2003) with load 
> balancing. 
> The webserver also uses mod_proxy to forward some requests to an IIS5 server 
> running on the same server but on a 
> different port. 
> The IIS5 hosts an Episerver 3 installation.
> 
> To speed things up, Apache webserver is serving the /images folder used by 
> Episerver using an Alias directive
> 
> Alias /images "E:/Inetpub/EPiServer3/root/images"
> <Directory "E:/Inetpub/EPiServer3/root/images">
>       Order deny,allow
>       Allow from all
> </Directory>
> 
> For mod_jk, the uriworkermap.properties -file specifies that all requests to 
> /images/... should be sent to 
> Apache Tomcat since the webapp contains a lot of images with that path
> 
> /images/*=wlb

So the short version is that you have two images directories, with the
same external path and you want overlapping mappings?

Inventing some complex solution to resolve it seems like a poor choice
to me.  If you have control of one or either of the applications I'd
adjust the path to the images instead.

Otherwise you're probably looking at individually mapping each image
file, which would be tedious.

A simple solution will be better in the long run.

p



> Is there some way to achieve any of the following behaviours?:
> 
> 1.    A request for /images/logo.jpg is processed by Apache webserver (This 
> file is located on the Apache webserver, in
>       E:/Inetpub/EPiServer3/root/images)
> 2.    Mod_jk forwards the request to an Apache Tomcat server which returns a 
> 404 since logo.jpg does not exist
>       on the server
> 3.    Apache webserver detects this 404 response and fetches logo.jpg from 
> E:/Inetpub/EPiServer3/root/images and returns it
> 
> Alternative
> 
> 1.    Same as above
> 2.    Apache webserver returns logo.jpg from E:/Inetpub/EPiServer3/root/images
> (3.   In the case that logo.jpg is not found in 
> E:/Inetpub/EPiServer3/root/images, an attempt is made to send the request to 
>       the Apache Tomcat server using mod_jk)
> 
> I have done some research and came accross the mod_jk option 
> ForwardDirectories but it doesnt seem to handle any of the above
> scenarios? It seems more related to directory indexing?! (I'm quite new with 
> Apache Webserver / Apache Tomcat :-) )
> 
> Thank you for your attention!
> 
> Best Regards
> /Andreas Imner
> 
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: users-h...@tomcat.apache.org
> 
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org

Reply via email to