hc-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Oleg Kalnichevski (JIRA)" <j...@apache.org>
Subject [jira] Commented: (HTTPCORE-148) Create AsyncNHttpServiceHandler & AsyncNHttpClientHandler
Date Thu, 21 Feb 2008 22:28:19 GMT

    [ https://issues.apache.org/jira/browse/HTTPCORE-148?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12571213#action_12571213

Oleg Kalnichevski commented on HTTPCORE-148:

> Would it be possible to leave thread-safety requirements to implementations

I do not think this is going to work. NHttpConnection instances are inherently threading unsafe
and may only be read from or written to either by the I/O dispatch thread or through IOControl
interface. It is just much easier to take care of this inside AsyncNHttpServiceHandler and,
more importantly, it is proper and cleaner. Besides, it is not that hard: stick a response
object to the connection state, call IOControl#requestOutput, submit the response in the #responseReady
method on the I/O dispatch thread. Done.


> Create AsyncNHttpServiceHandler & AsyncNHttpClientHandler
> ---------------------------------------------------------
>                 Key: HTTPCORE-148
>                 URL: https://issues.apache.org/jira/browse/HTTPCORE-148
>             Project: HttpComponents HttpCore
>          Issue Type: New Feature
>          Components: HttpCore NIO
>    Affects Versions: 4.0-beta1
>            Reporter: Sam Berlin
>            Assignee: Oleg Kalnichevski
>             Fix For: 4.0-beta2
>         Attachments: changes.txt, changes.txt, changes2.txt
> Attached is a patch for AsyncNHttpServiceHandler.  It actually works (as tested by running
& hitting it with IE.)  :)
> To test, run the example 'AsyncNHttpFileServer' in the examples directory or the TestAsyncNHttpHandlers

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: dev-unsubscribe@hc.apache.org
For additional commands, e-mail: dev-help@hc.apache.org

View raw message