Skip to content

🐛 Cloudflare caches 404's with the same TTL as everything else #4965

Description

@lukecookssw

Describe the bug
We have a cache config problem where Cloudflare is using the same 7-day TTL for 404 status codes as it does for 200 status codes.
This creates a problem where a new file is uploaded to a given route - e.g. ssw.com.au/images/some-new-image.jpg but it's not updated at the edge until the TTL ticks over.

Expected behavior
Cache settings should have a much lower TTL for 404 status codes so that new assets and routes are propagated more quickly to the edge.

See attached report.

cloudflare-cache-rules-404-fix.html

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type: BugA problem with existing functionality

    Type

    No type

    Projects

    Status
    🤷‍♂️ Needs Triage

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions