AnsweredAssumed Answered

Help with setting up Downstream Caching

Question asked by Ketan Shah on Jun 13, 2017
Latest reply on Jun 22, 2017 by Gunther Kochmann

Trying to setup downstream caching for our js scripts. Here is what is required:

 

  • Set the Edge Control Headers via apache ( since these are java script files)
  • Cache the specific java scripts on the Edge Server for 1 day
  • Cache the specific java scripts on the Browser for 1 hour

 

 

Apache setup is as follows: ( For testing we have setup a single js script )

 

<FilesMatch "load\.js$">

    Header set Edge-Control !no-store

    Header Append Edge-Control max-age=1d

    Header Append Edge-Control downstream-ttl=1h

</FilesMatch>

 

Current Property Manager Setup:

 

Downstream Cacheability -> Allow Caching, Cache Lifetime is set to Smaller Value: Origin Header or remaining edge TTL, Send Headers-> send both cache-control and expires

 

When looking at the curl headers, I see following

Cache-Control: max-age=86400
Expires: Sat, 03 Jun 2017 14:24:34 GMT 
Date: Fri, 02 Jun 2017 14:24:34 GMT

 

Should not the Expires be only 1 hour?

Outcomes