hkhl.
CDCloudflare Developers
•Created by hkhl. on 1/4/2024 in #workers-help
[Cloudflare image resizing] persistent Error 9412 /HTTP 415 (apparently no origin revalidation)
I tried to reproduce the origin state changes during the upload and there is a timeslot (stage 2, ~10 sec) while the upload is in progress where error 9412 /HTTP 415 seems the correct response. As far as I can see, the stages are
1) HTTP 404 (
3) HTTP 200 (
Content-Type: application/xml, No Etag, No Cache-Control, No Last-Modified-At
)
2) HTTP 200 (Content-Lenght: 0, Content-Type: image/jpeg, ETag: .., Last-Modified-At: ..., No Cache-Control
)3) HTTP 200 (
Content-Lenght: ... , Content-Type: image/jpeg, ETag: .., Last-Modified-At: ..., No Cache-Control
)
Stage 3 definitely returns the correct Image (it is picked up after the complete cache purge)
I can see that stage 2 should trigger Error 9412 /HTTP 415, but it sends no Cache-Control
, a different ETag
, and a Last -Modified-At
that is before the stage 3 Last-Modified-At
.
Any stage 3 revalidation requests from Cloudflare with If-Modified-Since
or If-None-Match
would return the full image (I double-checked with curl), but it seems that Cloudflare caches the upstream response of stage 2 forever.
Is this the expected behaviour? It only happens when there are resizing requests during stage 2 (That's why it never happened before going to production)2 replies