Have you thought of using something designed for this like Squid?
Apache httpd is a little heavy duty to just be a caching proxy.
--David
Neise, Volker wrote:
Hi,
I am running Apache 2.0 with tomcat 4.1.29. The problem is performance: at the moment requests are going
to "Apache A". If the request is a JSP, than the request is handled by Tomcat via mod_jk. Tomcat
runs and collects content out of a database and returns this to "Apache A". The time for
handling a request is at the upper limit and I want to improve this.
As most content does not change so often, my idea is to use another Apache for "reverse
proxy" and caching. I studied the Apache manual and found out thaz a szenario can look like
this:
(Apache Frontend) | (Apache A) | (Tomcat Backend)
(as proxy and cache) | (=Backend) |
| |
handles client requests | |
--------------------- proxy ---> handles forwarded req. |
| |
| ----------------- mod_jk ------ handles jsp
| -- other pages |
--- caching |
I installed this and it works fine - nearly. The proxy works and the cache also. But the Apache Frontend caches only those pages, which are handled by the Apache Backend directly (I find gifs, jpgs, js and so on in the cache-directory). I do NOT find any pages which are handled by the Tomcat.
Any idea what is wrong?
The Apache Frontnend httpd.conf looks like this
- - snip - -
# Reverse Proxy
ProxyRequests Off
<Proxy *>
Order deny,allow
Allow from all
</Proxy>
ProxyPass / http://backend-apache/
ProxyPassReverse / http://backend-apache/
#mod_cache Directive
CacheRoot "/cache"
CacheSize 55
CacheDefaultExpire 259200
CacheMaxExpire 604800
CacheEnable disk /
CacheDirLevels 5
CacheDirLength 3
CacheIgnoreCacheControl On
CacheIgnoreNoLastMod On
CacheLastModifiedFactor 0.1
- - snip - -
Your cooperation is welcome.
Mit freundlichen Gr��en, Volker Neise
---------------------------------------------------------------------
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]