[ 
https://issues.apache.org/jira/browse/HTTPCORE-45?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Oleg Kalnichevski resolved HTTPCORE-45.
---------------------------------------

    Resolution: Fixed

Hi Steffen,

I looked into the possibility of using a queue to keep track of incoming 
requests and came to realize that request pipelining and support for 'expect: 
continue' handshake are pretty much mutually exclusive. I think it is more 
important to have  support for the 'expect: continue' handshake than request 
queuing in Core. This will also help address Roland's concerns about HttpCore 
scope creep. So, I fixed the problem, as you initially suggested, by disabling 
read events while processing requests and streaming out responses.

I checked in a fix for the problem to the SVN trunk. Please review and let me 
know what you think

Olrh



> Pipelined requests cause HttpException
> --------------------------------------
>
>                 Key: HTTPCORE-45
>                 URL: https://issues.apache.org/jira/browse/HTTPCORE-45
>             Project: HttpComponents Core
>          Issue Type: Bug
>          Components: HttpCore NIO
>            Reporter: Steffen Pingel
>         Assigned To: Oleg Kalnichevski
>             Fix For: 4.0-alpha4
>
>         Attachments: httpcomponents-nio-pipelining-fix.txt
>
>
> I have a simple server implementation that uses DefaultServerIOEventDispatch 
> and BufferingHttpServiceHandler. Pipelined requests can cause an exception 
> when DefaultNHttpServerConnection receives another request while still 
> processing the response to a previous request:
> org.apache.http.HttpException: Response already submitted
>       at 
> org.apache.http.impl.nio.DefaultNHttpServerConnection.submitResponse(DefaultNHttpServerConnection.java:162)
>       at 
> org.apache.http.nio.protocol.BufferingHttpServiceHandler.commitResponse(BufferingHttpServiceHandler.java:369)
>       at 
> org.apache.http.nio.protocol.BufferingHttpServiceHandler.processRequest(BufferingHttpServiceHandler.java:358)
>       at 
> org.apache.http.nio.protocol.BufferingHttpServiceHandler.requestReceived(BufferingHttpServiceHandler.java:167)
>       at 
> org.apache.http.impl.nio.DefaultNHttpServerConnection.consumeInput(DefaultNHttpServerConnection.java:97)
>       at 
> org.apache.http.impl.nio.DefaultServerIOEventDispatch.inputReady(DefaultServerIOEventDispatch.java:77)
> [...]

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to