[ISSUE #5856] Support configurable max-initial-line-length for HTTP request decoder#6378
Open
hqbhonker wants to merge 1 commit into
Open
[ISSUE #5856] Support configurable max-initial-line-length for HTTP request decoder#6378hqbhonker wants to merge 1 commit into
hqbhonker wants to merge 1 commit into
Conversation
Add HTTP request decoder configuration support including: - maxInitialLineLength (default 4096) - maxHeaderSize (default 8192) - maxChunkSize (default 8192) Users can now configure these properties via application.yml: shenyu.netty.http.httpDecoder.maxInitialLineLength=8192 This resolves the issue where HTTP requests with URLs exceeding 4096 bytes are rejected by the gateway. Closes apache#5856
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
This PR adds support for configuring the HTTP request decoder properties in ShenYu Gateway, resolving the issue where HTTP requests with long URLs (exceeding 4096 bytes) are rejected.
Changes
shenyu-common
HttpDecoderPropertiesinner class toNettyHttpPropertieswith:maxInitialLineLength(default: 4096)maxHeaderSize(default: 8192)maxChunkSize(default: 8192)shenyu-spring-boot-starter-gateway
ShenyuNettyWebServerConfigurationto apply httpRequestDecoder settings from configurationshenyu-bootstrap
application.ymlConfiguration Example
How to Test
shenyu.netty.http.httpDecoder.maxInitialLineLength=8192in application.ymlChecklist
Closes #5856