apache / apache/trafficserver

ats has problems handling if-none-match requests for compressed objects

Open
#9,496 1 comment 0 reactions 1 assignee Claimed by @ezelkow1 View on GitHub
Stale Support
Dominant language
C++
Stars
2k
Forks
874
Avg merge
6d 15h
Merged PRs (30d)
46

Description

When using the compress plugin, ats appends the “-df” suffix to the Etag for the generated compressed object.

However, when ats responds to the if-none-match conditional request on the compressed object, it always uses the original Etag(without "-df" suffix), so it cannot return 304 properly.

![image](https://user-images.githubusercontent.com/13267484/223011299-95801e17-9019-4379-9418-0cb666d39997.png)

currently i use lua plugin to get a workaround.

`local c_req_hdr = ts.client_request.header['If-None-Match']`
`ts.client_request.header['If-None-Match'] = string.gsub(c_req_hdr, "-df", "")`

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.