-
Notifications
You must be signed in to change notification settings - Fork 26.4k
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
Triple http limiting the size of the HTTP request and response #14246
Conversation
@oxsean PTAL |
...ttp12/src/main/java/org/apache/dubbo/remoting/http12/exception/HttpOverPayloadException.java
Show resolved
Hide resolved
# Conflicts: # dubbo-remoting/dubbo-remoting-http12/src/main/java/org/apache/dubbo/remoting/http12/netty4/h1/NettyHttp1Channel.java
...ing-http12/src/main/java/org/apache/dubbo/remoting/http12/h1/LimitedByteBufOutputStream.java
Outdated
Show resolved
Hide resolved
...ttp12/src/main/java/org/apache/dubbo/remoting/http12/exception/HttpOverPayloadException.java
Show resolved
Hide resolved
I think h2 respone also need limit respone size. |
...ttp12/src/main/java/org/apache/dubbo/remoting/http12/h1/Http1ServerUnaryChannelObserver.java
Outdated
Show resolved
Hide resolved
In http2:
|
A problem encountered is that errors may occur during serialization. At this time, if the header is written first, the status code will be 200, but the result is failure. |
Http2 no longer requires a content-length header, but some clients may use content-length to determine whether the data stream is complete. Therefore, refer to some common implementations in the industry to decide whether to add a content-length header to the http2 trailers, such as spring boot, tomcat, etc. |
…g should also be set when the http1 connection is disconnected
...o-rpc/dubbo-rpc-triple/src/main/java/org/apache/dubbo/rpc/protocol/tri/TripleHeaderEnum.java
Show resolved
Hide resolved
...ing-http12/src/main/java/org/apache/dubbo/remoting/http12/h1/LimitedByteBufOutputStream.java
Outdated
Show resolved
Hide resolved
# Conflicts: # dubbo-remoting/dubbo-remoting-http12/src/main/java/org/apache/dubbo/remoting/http12/netty4/h1/NettyHttp1Channel.java # dubbo-remoting/dubbo-remoting-http12/src/main/java/org/apache/dubbo/remoting/http12/netty4/h2/NettyH2StreamChannel.java
LGTM. |
@EarthChen PTAL |
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
Quality Gate passedIssues Measures |
What is the purpose of the change
refer: #14068
For example:
Success result:
Request body limit result:
Response body limit result:
Brief changelog
Verifying this change
Checklist