Clay Gerrard e0818f55b0 Ensure correct content-type in container HEAD response
A failing CORS test in the gate discovered that we were responding
application/json to ?format=txt requests (which is maybe not even a
valid value for that qs param?), but only when running with
eventlet==0.38.0

This avoids the problem of backend container server HEADs no longer
having 'Content-Length: 0' by fixing the client HEAD resp headers before
we check for chunked-transfer resp.

Drive-By: refactor listing_formats to use HeaderKeyDict and always set
Content-Length explicitly

Co-Authored-By: Alistair Coles <alistairncoles@gmail.com>
Co-Authored-By: Matthew Oliver <matt@oliver.net.au>

Change-Id: If724485e1425d1481d10b9255436301e346f07e8
(cherry picked from commit fa889358acf7675efba2de095777886b4c1ff7f8)
2024-12-02 17:26:53 +00:00
..
2023-01-19 12:56:08 -08:00
2020-05-15 22:38:04 -07:00