-
Notifications
You must be signed in to change notification settings - Fork 602
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
Only validate header name once (attempt #2) #24499
Only validate header name once (attempt #2) #24499
Conversation
b86e84a
to
1aaafe6
Compare
#libby #build |
Your personal build request is at https://wasrtc.hursley.ibm.com:9443/jazz/resource/itemOid/com.ibm.team.build.BuildResult/_zsHoALoUEe2r6re_Zvbagg Target locations of links might be accessible only to IBM employees. |
- Only validate header name when creating HttpHeaderKeys the first time. - Correctly validate byte[] header names. byte[].toString doesn't give you a String of the byte[] contents. - Make all HttpHeaderKeys constructors private to prevent anyone creating one without validation.
1aaafe6
to
5704517
Compare
#libby #build |
Your personal build request is at https://wasrtc.hursley.ibm.com:9443/jazz/resource/itemOid/com.ibm.team.build.BuildResult/_f-6C4L68Ee2o6J5YNcso_g Target locations of links might be accessible only to IBM employees. |
- For get, contains, and remove do not throw IllegalArgumentException when the header name is invalid. Just ignore the header and do not created a HttpHeaderKeys object. - Update HttpTrailerGeneratorImpl to do the correct equals. The code never would work as it was written.
- Add test cases for invalid header names and make sure for containers, get and remove methods that we don't throw an exception, but for set and append methods we do throw an exception
5704517
to
c356deb
Compare
#libby |
Code analysis and actionsDO NOT DELETE THIS COMMENT.
|
The build jhanders34-24499-20230310-0614 For help analyzing your personal build, go to https://cognitive.hursley.ibm.com/buildAnalysis.html?uuid=_NiELUL9EEe2o6J5YNcso_g |
The build jhanders34-24499-20230310-0614 For help analyzing your personal build, go to https://cognitive.hursley.ibm.com/buildAnalysis.html?uuid=_Tirp8L9EEe2o6J5YNcso_g |
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.
LGTM, thanks for the work improving the performance here!
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.
Thanks, Jared!
Fixes #24427
This pull request is redo of PR #24382. It is a performance improvement for the changes done in #24157. Also going to tag #24187 since that is the PR associated with #24157.