I'm constantly getting this error when passing URLs through.
org.jboss.netty.handler.codec.frame.TooLongFrameException: HTTP header is larger than 8192 bytes.
at org.jboss.netty.handler.codec.http.HttpMessageDecoder.readHeader(HttpMessageDecoder.java:624)
at org.jboss.netty.handler.codec.http.HttpMessageDecoder.readHeaders(HttpMessageDecoder.java:531)
at org.jboss.netty.handler.codec.http.HttpMessageDecoder.decode(HttpMessageDecoder.java:195)
at org.jboss.netty.handler.codec.http.HttpClientCodec$Decoder.decode(HttpClientCodec.java:143)
at org.jboss.netty.handler.codec.http.HttpClientCodec$Decoder.decode(HttpClientCodec.java:127)
at org.jboss.netty.handler.codec.replay.ReplayingDecoder.callDecode(ReplayingDecoder.java:500)
at org.jboss.netty.handler.codec.replay.ReplayingDecoder.messageReceived(ReplayingDecoder.java:485)
at org.jboss.netty.channel.SimpleChannelUpstreamHandler.handleUpstream(SimpleChannelUpstreamHandler.java:70)
at org.jboss.netty.handler.codec.http.HttpClientCodec.handleUpstream(HttpClientCodec.java:92)
at org.jboss.netty.channel.DefaultChannelPipeline.sendUpstream(DefaultChannelPipeline.java:564)
at org.jboss.netty.channel.DefaultChannelPipeline.sendUpstream(DefaultChannelPipeline.java:559)
at org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:268)
at org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:255)
at org.jboss.netty.channel.socket.nio.NioWorker.read(NioWorker.java:88)
at org.jboss.netty.channel.socket.nio.AbstractNioWorker.process(AbstractNioWorker.java:108)
at org.jboss.netty.channel.socket.nio.AbstractNioSelector.run(AbstractNioSelector.java:337)
at org.jboss.netty.channel.socket.nio.AbstractNioWorker.run(AbstractNioWorker.java:89)
at org.jboss.netty.channel.socket.nio.NioWorker.run(NioWorker.java:178)
at org.jboss.netty.util.ThreadRenamingRunnable.run(ThreadRenamingRunnable.java:108)
at org.jboss.netty.util.internal.DeadLockProofWorker$1.run(DeadLockProofWorker.java:42)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
Is there a way to increase maxHeaderSize? I've tried -Dhttp.netty.maxHeaderSize and -Dplay.server.netty.maxHeaderSize, but neither of them do the trick even though maxInitialLineLength can be modified using either of those options.
Any help would be appreciated. Thanks!
The URL for a request is not an HTTP header, it's in the initial line, so you need to configure -Dhttp.netty.maxInitialLineLength or -Dplay.server.netty.maxInitialLineLength depending on which version of Play you're using.
Can someone, please, help me understand what the "initial line" is?
Edit: oh it is the initial request line I suppose, https://www.jmarshall.com/easy/http/ for anyone wondering
maxInitialLineLength is the maximum length of the initial line (e.g. "GET /
HTTP/1.0" or "HTTP/1.0 200 OK") of the HTTP request or response. The URL
is part of that line.
Will Sargent
_Engineer, Lightbend, Inc._
will.[email protected]
On Thu, Aug 11, 2016 at 6:03 AM, Josef Pacula [email protected]
wrote:
Can someone, please, help me understand what the "initial line" is?
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/playframework/playframework/issues/5036#issuecomment-239154234,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AAEWRKNxF5Dg7NrgtUADbAi7qYSTpUamks5qex2IgaJpZM4Fxx6t
.
Most helpful comment
The URL for a request is not an HTTP header, it's in the initial line, so you need to configure
-Dhttp.netty.maxInitialLineLengthor-Dplay.server.netty.maxInitialLineLengthdepending on which version of Play you're using.