Skip to content

Avatars not getting cached by CDN #143

@calpaterson

Description

@calpaterson

Description

User avatars should be cached for 5 minutes, including by the CDN.

Instead cloudflare views them as dynamic (cf-cache-status: DYNAMIC) and every request is going through to the app server

Steps to reproduce

  1. curl https://csvbase.com/avatars/calpaterson

Expected result

cf-cache-status is HIT or MISS, depending on situation at the CDN

Actual result

cf-cache-status is DYNAMIC, meaning that they queried origin

Additional details

Apparently this is about file extensions or something.

Cloudflare has been configured with a quick hack to ensure this doesn't happen in production, but clearly some kind of code change is needed

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions