-
Notifications
You must be signed in to change notification settings - Fork 38.7k
Description
Affects: 5.1
Hello,
currently HttpHeaders
' documentation does not acknowledge that HttpHeaders
behave in case-insensitive manner.
Per RFC 7230:
Each header field consists of a case-insensitive field name followed by a colon (":"), optional leading whitespace, the field value, and optional trailing whitespace.
It may be confusing in the presence of publicly exposed HttpHeaders(MultiValueMap<String, String>)
constructor by this commit.
Do I understand right that the constructor is intended to be used by the framework itself only? @bclozel
Here is a question on StackOverflow asking whether the HttpHeaders
are case-insensitive.
I had answered the question relying on the fact that there had been only one publicly available constructor utilized LinkedCaseInsenitiveMap
underneath.
But now I'm a little bit doubtful because of the HttpHeaders(MultiValueMap<String, String>)
constructor.
I've edited the answer accordingly
May I submit a pull request clarifying the documentation that:
HttpHeaders
are case-insensitiveHttpHeaders(MultiValueMap<String, String>)
is only for internal use (if the fact is acknowledged)
?
Thank you for your time