We have apache servers that proxy content from an application server and also from a legacy web server. We enabled caching using our load balancer, but the caching is not behaving like we expect it to. Here is our setup:

We're setting cache headers specifically for the pages served from our application server using:

<Location ~ /(appDir1|appDir2|appDir3)>
Header set Cache-Control max-age=3600,public

This works fine.

On the legacy server, the sys admin has set this in his Apache virtual host that runs his legacy site:

Header set Cache-Control max-age=0,private,no-cache

However, our load balancers are still caching the legacy content that we proxy.

When we visit http://appHost/legacyDir1 - we see cached content. When we visit http://legacyHost/legacyDir1 - we see the non-cached content. At least in theory, we're expecting to see non-cached at http://appHost/legacyDir1.

Any ideas what we might be missing ... ?



The issue was with the load balancer settings. The LB had to be configured to match the various pages that needed to be cached.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.