Possible to set Cache-Control on S3 Uploads?

  • Goal: Reduce our CDN costs! Lack of a Cache-Control header leads to excessive requests to our CDN costing us big $$$$

  • Problem: Upload a file from S3 Uploader. No Cache-Control header is set on the object on S3. CDN then does client caching using If-Modified-Since but this still counts as a REQUEST and results in a small fee per request. Setting a max-age header is proven to reduce these requests.

  • Details: On the S3 uploader, I can set the mime type, object name and some other settings, but I'm not sure if we can somehow set the other metadata we need on the object.

Hi @Garr_Godfrey,

Thanks for reaching out!

We are tracking requests to enable specifying custom metadata in S3 uploads, but we haven't been able to prioritize it yet :disappointed: I'll add your +1 internally

Is this something that you could workaround by using the S3 rest api in our generic rest api integration? You could use our generic file button & trigger an S3 Rest post request.

yes, that would probably work. We have a few dozen places to change, though, so I'm looking at using a lambda function to change on S3 side