-
Notifications
You must be signed in to change notification settings - Fork 121
Enhance the MultiReadHttpServletRequest stream #721
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
Conversation
|
Typo in commit message. MultiReadHttpServletReques |
gateway-ha/src/main/java/io/trino/gateway/proxyserver/MultiReadHttpServletRequest.java
Show resolved
Hide resolved
| public int read(byte[] b, int off, int len) | ||
| throws IOException | ||
| { | ||
| return byteArrayInputStream.read(b, off, len); |
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 want to make this null-safe?
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.
byteArrayInputStream is locally allocated, if that's what your concern is. It should not be null.
|
Is this good to to @vishalya @Chaho12 @oneonestar ? |
|
Seems ok. But don't forget to fix the commit message :) |
andythsu
left a comment
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 except for the commit msg
Chaho12
left a comment
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 👍
|
Build failed because of this issue #755 |
I don't think developers can understand changes from this commit title. Please add the commit body explaining what was enhanced. |
|
Updated the PR description. |
|
Thanks, please update the commit body too. |
|
Lets finish this off @vishalya .. add the info from the description to the commit message as discussed in team sync and then you can go ahead with merge. |
|
@vishalya Not sure why you ignored the above comment. |
Description
isFinishedshould be true only no bytes are available in the input stream to readisReadyshould always return true, since the inputstream should be ready all the time and never be false.Additional context and related issues
@Chaho12 has idea on the issue with this code. @willmostly is the original author.
Release notes
(X) This is not user-visible or is docs only, and no release notes are required.
( ) Release notes are required, with the following suggested text: