-
Notifications
You must be signed in to change notification settings - Fork 1.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fixed header cache for unknown values #11808
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Change look ok beside maybe not caching the no-space-after-column case, but broke other tests.
@@ -167,7 +167,8 @@ public class HttpParser | |||
for (HttpHeader h : HttpHeader.values()) | |||
{ | |||
HttpField httpField = new HttpField(h, UNMATCHED_VALUE); | |||
map.put(httpField.toString(), httpField); | |||
map.put(h + ": ", httpField); | |||
map.put(h + ":", httpField); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we really want to cache the no-space-after-column case?
It's bad formatting by the client, so it deserves less efficiency?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I added it in because I initially write a test that was just looking up "Content-Type:" (no space) and was surprised by the miss. But I will remove for now to just fix the issue and we can think about other optimizations separately.
Avoid adding the unknown marker into the CACHE index. Issue introduced in #11661 fixing #11659