Mutating ETag response header value for response gzipped with gzip.Middleware #143
pboguslawski
started this conversation in
Ideas
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
According to
https://www.rfc-editor.org/rfc/rfc7232#section-2.3.3
https://bz.apache.org/bugzilla/show_bug.cgi?id=46538
ETag
header values should be different for responses sent with and without content compression.Consider allowing to generate different ETags for plain and compressed responses, maybe adding
gzipETagSuffix
parameter togzip.Middleware
; whensuffix
is not empty, append it to existingETag
response header value (inside "") when response is gzipped.Now stripping such suffix from requests (i.e. version validation in API) will allow one to get original ETag value regardless of response encoding.
Beta Was this translation helpful? Give feedback.
All reactions