• I have selected the following settings:

    Browse Cache / General
    – Set Last-Modified header
    – Set expires header
    – Set cache control header
    – Set entity tag (eTag)

    Browse Cache / Media & Other Files
    – Set Last-Modified header
    – Set expires header
    – Expires header lifetime: 31536000
    – Set cache control header
    – Cache Control policy: “cache with max-age”
    – Set entity tag (eTag)

    When I “export the media library” to AWS S3, the assets uploaded have a “cache-control” value of just “public” when I expect them to have a value of “max-age=31536000, public” instead.

    https://ww.wp.xz.cn/plugins/w3-total-cache/

Viewing 5 replies - 1 through 5 (of 5 total)
  • The correct cache-control policy is set on static assets when the CDN is disabled?

    Thread Starter CCVonLewin

    (@ccvonlewin)

    When I disable the plugin and view the asset from the Media Library, the response header has: “Cache-Control:public, max-age=2592000”

    That’s not what I’m asking, sorry, I’m asking what the cache-control policy is set to when W3 Total Cache is active but the CDN component is disabled.

    Thread Starter CCVonLewin

    (@ccvonlewin)

    Under General Settings, “CDN” is unchecked and “Browser Cache” is enabled (checked) – since you did not ask to disable it. The response header i get from viewing the asset in the media library is: “Cache-Control:public, max-age=2592000”. hopefully that helps.

    Ok, can you try creating a new bucket? I would actually recommend just skipping S3 and connecting WordPress directly to a CloudFlare distribution unless you have some specific need for S3.

    S3 is an elastic data store (hard drive in the cloud), not a CDN. CloudFront is Amazon’s CDN product, which delivers better performance and more consistent results (not to mention not needing to export content when you configure it as origin pull).

Viewing 5 replies - 1 through 5 (of 5 total)

The topic ‘browser cache / media / cache control policy’ is closed to new replies.