Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
4.0-alpha5
-
None
Description
If the underlying channel has more data buffered than can be read into inbuf DefaultNHttpServerConnection.consumeInput() will return and relies on the selector to timeout to read the remaining part of the request. I suggest to make the parsing code more greedy:
int bytesRead;
while ((bytesRead = this.requestParser.fillBuffer(this.session.channel())) > 0 && this.request == null) {
if (bytesRead > 0)
this.request = (HttpRequest) this.requestParser.parse();
}