hc-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Supun Kamburugamuva <supu...@gmail.com>
Subject HTTP Core NIO tries to read the request line twice
Date Wed, 03 Mar 2010 14:06:50 GMT
Hi,
Hi,

We got the exception[2] from couple of users. But couldn't reproduce this on
our own.

>From the logs it seems that, before this exception
NHttpServiceHandler.inputReady method has being called for the same request.
Also the request line is logged and is perfectly valid. So my conclusion is
HTTP core tries to read the request headers twice and second time it fails.
The exception we got here is generated by a version that uses the Apache
HTTP Core 4.0.beta1. Also this same issue has being observed with the HTTP
Core 4.1.alpha1 as well [1].

Is this a known issue in HTTP Core? Or is there some way that we can avoid
this case? Any help will be greatly appreciated.

Thanks,
Supun..

[1] http://wso2.org/forum/thread/8867

[2] org.apache.http.ProtocolException: Invalid request line:
at
org.apache.http.impl.nio.codecs.AbstractMessageParser.parse(AbstractMessageParser.java:184)
at
org.apache.http.impl.nio.DefaultNHttpServerConnection.consumeInput(DefaultNHttpServerConnection.java:152)
at
org.apache.synapse.transport.nhttp.LoggingNHttpServerIOTarget.consumeInput(LoggingNHttpServerIOTarget.java:154)
at
org.apache.http.impl.nio.DefaultServerIOEventDispatch.inputReady(DefaultServerIOEventDispatch.java:147)
at
org.apache.http.impl.nio.reactor.BaseIOReactor.readable(BaseIOReactor.java:161)
at
org.apache.http.impl.nio.reactor.AbstractIOReactor.processEvent(AbstractIOReactor.java:339)
at
org.apache.http.impl.nio.reactor.AbstractIOReactor.processEvents(AbstractIOReactor.java:319)
at
org.apache.http.impl.nio.reactor.AbstractIOReactor.execute(AbstractIOReactor.java:275)
at
org.apache.http.impl.nio.reactor.BaseIOReactor.execute(BaseIOReactor.java:104)
at
org.apache.http.impl.nio.reactor.AbstractMultiworkerIOReactor$Worker.run(AbstractMultiworkerIOReactor.java:528)
at java.lang.Thread.run(Thread.java:636)
Caused by: org.apache.http.ParseException: Invalid request line:
at
org.apache.http.message.BasicLineParser.parseRequestLine(BasicLineParser.java:312)
at
org.apache.http.impl.nio.codecs.HttpRequestParser.createMessage(HttpRequestParser.java:75)
at
org.apache.http.impl.nio.codecs.AbstractMessageParser.parseHeadLine(AbstractMessageParser.java:133)
at
org.apache.http.impl.nio.codecs.AbstractMessageParser.parse(AbstractMessageParser.java:182)

-- 
Software Engineer, WSO2 Inc
http://wso2.org
supunk.blogspot.com

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message