Skip to content
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

How to configure max-initial-line-length in Shenyu Gateway? #5856

Open
titxue opened this issue Dec 18, 2024 · 0 comments
Open

How to configure max-initial-line-length in Shenyu Gateway? #5856

titxue opened this issue Dec 18, 2024 · 0 comments
Labels
type: question Further information is requested

Comments

@titxue
Copy link

titxue commented Dec 18, 2024

Question

I am encountering an issue with the default HTTP request line length limit in Shenyu (version 2.6.1). When a request URI exceeds 4096 bytes, I receive the following error:

2024-12-18 13:30:48.761  WARN 14228 --- [nyu-netty-nio-2] r.n.http.server.HttpServerOperations     : [d7d12014, L:/127.0.0.1:9195 - R:/127.0.0.1:59507] Decoding failed: FULL_REQUEST(decodeResult: failure(io.netty.handler.codec.http.TooLongHttpLineException: An HTTP line is larger than 4096 bytes.), version: HTTP/1.0, content: UnpooledByteBufAllocator$InstrumentedUnpooledUnsafeHeapByteBuf(ridx: 0, widx: 0, cap: 0))
GET /bad-request HTTP/1.0

I resolved this by modifying Netty's max-initial-line-length parameter using the following configuration in my server settings:

server:
  netty:
    max-initial-line-length: 409600

However, I couldn't find an equivalent configuration in Shenyu for this parameter. Could you please guide me on how to configure max-initial-line-length in Shenyu or if it's possible to extend this setting via custom configuration or plugin?

@titxue titxue added the type: question Further information is requested label Dec 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: question Further information is requested
Projects
None yet
Development

No branches or pull requests

1 participant